[PATCH v2 2/3] drm/amd/display: Don't queue FRL status polling on a NULL workqueue

From: Eren Özen via B4 Relay

Date: Wed Nov 18 2026 - 07:11:02 EST


From: Eren Özen <erenozen@xxxxxxxxxxxxxx>

If create_singlethread_workqueue() fails in amdgpu_dm_init(), the
driver only logs an error and continues with
hdmi_frl_status_polling_wq set to NULL. The next atomic commit whose
state contains an HDMI FRL stream then passes that NULL pointer to
queue_delayed_work(). When the 200ms timer fires,
delayed_work_timer_fn() dereferences it in __queue_work() and the
kernel oopses in softirq context.

Skip the polling when the workqueue is missing, the same way
amdgpu_dm_crtc_set_vblank() only queues vblank control work when
vblank_control_workqueue exists. FRL link status is then not polled,
but the display keeps working.

Fixes: 5c9b8b27a883 ("drm/amd/display: Tie FRL support into amdgpu_dm")
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Eren Özen <erenozen@xxxxxxxxxxxxxx>
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
index af7acfbbf9e0..201aba79e43b 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -4891,7 +4891,7 @@ static void amdgpu_dm_commit_streams(struct drm_atomic_commit *state,
}
}

- if (frl_stream_found) {
+ if (frl_stream_found && dm->hdmi_frl_status_polling_wq) {
if (queue_delayed_work(dm->hdmi_frl_status_polling_wq,
&dm->hdmi_frl_status_polling_work,
msecs_to_jiffies(dm->hdmi_frl_status_polling_delay_ms)))

--
2.56.0