From 180eb82d246240126842f4c5a4f7005cb754a7b2 Mon Sep 17 00:00:00 2001 From: jsg Date: Mon, 5 Aug 2024 02:37:12 +0000 Subject: [PATCH] drm/amd/display: Check for NULL pointer From Sung Joon Kim 4ccd37085976ea5d3c499b1e6d0b3f4deaf2cd5a in linux-6.6.y/6.6.44 4ab68e168ae1695f7c04fae98930740aaf7c50fa in mainline linux --- sys/dev/pci/drm/amd/display/dc/core/dc_surface.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/dev/pci/drm/amd/display/dc/core/dc_surface.c b/sys/dev/pci/drm/amd/display/dc/core/dc_surface.c index a80e4530078..f4f3ca7aad6 100644 --- a/sys/dev/pci/drm/amd/display/dc/core/dc_surface.c +++ b/sys/dev/pci/drm/amd/display/dc/core/dc_surface.c @@ -154,7 +154,8 @@ const struct dc_plane_status *dc_plane_get_status( if (pipe_ctx->plane_state != plane_state) continue; - pipe_ctx->plane_state->status.is_flip_pending = false; + if (pipe_ctx->plane_state) + pipe_ctx->plane_state->status.is_flip_pending = false; break; } -- 2.20.1