Skip to contentSkip to conversation

FAILED: patch "[PATCH] media: ti: vpe: unwind v4l2 device registration on probe" failed to apply to 5.10-stable tree

PATCH [email protected] 1 participant 1 message Jul 29

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 5.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.10.y
git checkout FETCH_HEAD
git cherry-pick -x e0f1c9a90ef665f2587c274a8fed59f2dfc575a6
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026072938-citation-surely-2ef4@gregkh' --subject-prefix 'PATCH 5.10.y' 'HEAD^..'

Possible dependencies:

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From e0f1c9a90ef665f2587c274a8fed59f2dfc575a6 Mon Sep 17 00:00:00 2001
From: Myeonghun Pak <[email protected]>
Date: Sun, 26 Apr 2026 22:16:31 +0900
Subject: [PATCH] media: ti: vpe: unwind v4l2 device registration on probe
error

If the vpe_top resource is missing, vpe_probe() returns -ENODEV after v4l2_device_register() has succeeded. Probe failures do not call the driver's remove callback, so the v4l2 device remains registered on that error path.

Route that failure through the existing v4l2_device_unregister() unwind label, matching the other errors after v4l2_device_register().

Fixes 4d59c7d45585 ("media: ti-vpe: vpe: Add missing null pointer checks")
drivers/media/platform/ti/vpe/vpe.c +2 -1
index a7e5a85e72a1..81bd1f9cee30 100644
@@ -2539,7 +2539,8 @@ static int vpe_probe(struct platform_device *pdev)
 						"vpe_top");
 	if (!dev->res) {
 		dev_err(&pdev->dev, "missing 'vpe_top' resources data\n");
-		return -ENODEV;
+		ret = -ENODEV;
+		goto v4l2_dev_unreg;
 	}
 
 	/*