FAILED: patch "[PATCH] drm/mediatek: Fix probe device leaks" failed to apply to 6.6-stable tree
Subsystems (4)
[email protected]
maintainerThe patch below does not apply to the 6.6-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-6.6.y
git checkout FETCH_HEAD
git cherry-pick -x 2a2a04be8e869a19c9f950b89b1e05832a0f7ec7
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026010535-promptly-succulent-ecc2@gregkh' --subject-prefix 'PATCH 6.6.y' HEAD^..
Possible dependencies:
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 2a2a04be8e869a19c9f950b89b1e05832a0f7ec7 Mon Sep 17 00:00:00 2001
From: Johan Hovold <[email protected]>
Date: Tue, 23 Sep 2025 17:23:38 +0200
Subject: [PATCH] drm/mediatek: Fix probe device leaks
Make sure to drop the reference taken to each component device during probe on probe failure (e.g. probe deferral) and on driver unbind.
drivers/gpu/drm/mediatek/mtk_ddp_comp.c +11 -0
@@ -621,6 +621,13 @@ int mtk_find_possible_crtcs(struct drm_device *drm, struct device *dev)return ret; } +static void mtk_ddp_comp_put_device (void *_dev) +{ +struct device *dev = _dev; + +put_device (dev); +} +static void mtk_ddp_comp_clk_put (void *_clk) {struct clk *clk = _clk;
@@ -656,6 +663,10 @@ int mtk_ddp_comp_init(struct device *dev, struct device_node *node, struct mtk_d } comp->dev = &comp_pdev->dev; + ret =devm_add_action_or_reset (dev, mtk_ddp_comp_put_device, comp->dev); +if (ret) +return ret; + if (type == MTK_DISP_AAL || type == MTK_DISP_BLS || type == MTK_DISP_CCORR ||