From: Leo (Hanghong) Ma Date: Thu, 19 Sep 2024 19:19:29 +0000 (-0400) Subject: drm/amd/display: Fix Coverity change for visual confirm X-Git-Tag: v6.13-rc1~122^2~15^2~74 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=74a55071dd9c1f75abc942bda964cab3684c780c;p=thirdparty%2Fkernel%2Flinux.git drm/amd/display: Fix Coverity change for visual confirm [Why && How] Previous change for Coverity has caused regression on visual confirm so fix it by reverting the part that affects visual confirm. Reviewed-by: Chris Park Signed-off-by: Leo (Hanghong) Ma Signed-off-by: Roman Li Tested-by: Daniel Wheeler Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/display/dc/dc_dmub_srv.c b/drivers/gpu/drm/amd/display/dc/dc_dmub_srv.c index 9291f078ffde7..8486c144d81ca 100644 --- a/drivers/gpu/drm/amd/display/dc/dc_dmub_srv.c +++ b/drivers/gpu/drm/amd/display/dc/dc_dmub_srv.c @@ -519,7 +519,8 @@ void dc_dmub_srv_get_visual_confirm_color_cmd(struct dc *dc, struct pipe_ctx *pi union dmub_rb_cmd cmd = { 0 }; unsigned int panel_inst = 0; - if (!dc_get_edp_link_panel_inst(dc, pipe_ctx->stream->link, &panel_inst)) + if (!dc_get_edp_link_panel_inst(dc, pipe_ctx->stream->link, &panel_inst) && + dc->debug.visual_confirm == VISUAL_CONFIRM_DISABLE) return; memset(&cmd, 0, sizeof(cmd));