]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/gud: fix NULL fb and crtc dereferences on USB disconnect
authorShenghao Yang <me@shenghaoyang.info>
Wed, 31 Dec 2025 05:50:26 +0000 (13:50 +0800)
committerRuben Wauters <rubenru09@aol.com>
Tue, 13 Jan 2026 13:58:24 +0000 (13:58 +0000)
commitdc2d5ddb193e363187bae2ad358245642d2721fb
tree8164ccf86651e90c515fa813c9116958664a3953
parent9380dc33cd6ae4a6857818fcefce31cf716f3fae
drm/gud: fix NULL fb and crtc dereferences on USB disconnect

On disconnect drm_atomic_helper_disable_all() is called which
sets both the fb and crtc for a plane to NULL before invoking a commit.

This causes a kernel oops on every display disconnect.

Add guards for those dereferences.

Cc: <stable@vger.kernel.org> # 6.18.x
Fixes: 73cfd166e045 ("drm/gud: Replace simple display pipe with DRM atomic helpers")
Signed-off-by: Shenghao Yang <me@shenghaoyang.info>
Reviewed-by: Ruben Wauters <rubenru09@aol.com>
Signed-off-by: Ruben Wauters <rubenru09@aol.com>
Link: https://patch.msgid.link/20251231055039.44266-1-me@shenghaoyang.info
drivers/gpu/drm/gud/gud_pipe.c