]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/tegra: rgb: Fix the unbound reference count
authorBiju Das <biju.das.jz@bp.renesas.com>
Wed, 5 Feb 2025 11:21:35 +0000 (11:21 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2025 10:05:11 +0000 (11:05 +0100)
commit809b522315a0d8b6815294e3c17effbff163c115
treec446f8a94b08a086980a9b2948b029f7ce9129ec
parentafc9153b1e576a5225e2f680774a1afa9bb56fdb
drm/tegra: rgb: Fix the unbound reference count

[ Upstream commit 3c3642335065c3bde0742b0edc505b6ea8fdc2b3 ]

The of_get_child_by_name() increments the refcount in tegra_dc_rgb_probe,
but the driver does not decrement the refcount during unbind. Fix the
unbound reference count using devm_add_action_or_reset() helper.

Fixes: d8f4a9eda006 ("drm: Add NVIDIA Tegra20 support")
Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://lore.kernel.org/r/20250205112137.36055-1-biju.das.jz@bp.renesas.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/tegra/rgb.c