[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <DEJCLD92ZKB0.3ABKT4189ASSV@bootlin.com>
Date: Thu, 27 Nov 2025 09:52:15 +0100
From: "Luca Ceresoli" <luca.ceresoli@...tlin.com>
To: "Kory Maincent" <kory.maincent@...tlin.com>, "Tomi Valkeinen"
<tomi.valkeinen@...asonboard.com>, "Maxime Ripard" <mripard@...nel.org>,
"Douglas Anderson" <dianders@...omium.org>,
<dri-devel@...ts.freedesktop.org>, <linux-kernel@...r.kernel.org>
Cc: "Bajjuri Praneeth" <praneeth@...com>, "Louis Chauvet"
<louis.chauvet@...tlin.com>, <stable@...r.kernel.org>,
<thomas.petazzoni@...tlin.com>, "Jyri Sarha" <jyri.sarha@....fi>, "Maarten
Lankhorst" <maarten.lankhorst@...ux.intel.com>, "Thomas Zimmermann"
<tzimmermann@...e.de>, "David Airlie" <airlied@...il.com>, "Simona Vetter"
<simona@...ll.ch>
Subject: Re: [PATCH v4] drm/tilcdc: Fix removal actions in case of failed
probe
On Tue Nov 25, 2025 at 10:05 AM CET, Kory Maincent wrote:
> From: "Kory Maincent (TI.com)" <kory.maincent@...tlin.com>
>
> The drm_kms_helper_poll_fini() and drm_atomic_helper_shutdown() helpers
> should only be called when the device has been successfully registered.
> Currently, these functions are called unconditionally in tilcdc_fini(),
> which causes warnings during probe deferral scenarios.
>
> [ 7.972317] WARNING: CPU: 0 PID: 23 at drivers/gpu/drm/drm_atomic_state_helper.c:175 drm_atomic_helper_crtc_duplicate_state+0x60/0x68
> ...
> [ 8.005820] drm_atomic_helper_crtc_duplicate_state from drm_atomic_get_crtc_state+0x68/0x108
> [ 8.005858] drm_atomic_get_crtc_state from drm_atomic_helper_disable_all+0x90/0x1c8
> [ 8.005885] drm_atomic_helper_disable_all from drm_atomic_helper_shutdown+0x90/0x144
> [ 8.005911] drm_atomic_helper_shutdown from tilcdc_fini+0x68/0xf8 [tilcdc]
> [ 8.005957] tilcdc_fini [tilcdc] from tilcdc_pdev_probe+0xb0/0x6d4 [tilcdc]
>
> Fix this by rewriting the failed probe cleanup path using the standard
> goto error handling pattern, which ensures that cleanup functions are
> only called on successfully initialized resources. Additionally, remove
> the now-unnecessary is_registered flag.
>
> Cc: stable@...r.kernel.org
> Fixes: 3c4babae3c4a ("drm: Call drm_atomic_helper_shutdown() at shutdown/remove time for misc drivers")
> Signed-off-by: Kory Maincent (TI.com) <kory.maincent@...tlin.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@...tlin.com>
--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Powered by blists - more mailing lists