Skip to content
This repository was archived by the owner on Nov 8, 2023. It is now read-only.

Commit 65b2d49

Browse files
Alex Hunggregkh
authored andcommitted
drm/amd/display: Check null pointer before dereferencing se
[ Upstream commit ff599ef ] [WHAT & HOW] se is null checked previously in the same function, indicating it might be null; therefore, it must be checked when used again. This fixes 1 FORWARD_NULL issue reported by Coverity. Acked-by: Alex Hung <[email protected]> Reviewed-by: Rodrigo Siqueira <[email protected]> Signed-off-by: Alex Hung <[email protected]> Tested-by: Daniel Wheeler <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Signed-off-by: Sasha Levin <[email protected]>
1 parent 0ef6e01 commit 65b2d49

File tree

1 file changed

+1
-1
lines changed
  • drivers/gpu/drm/amd/display/dc/core

1 file changed

+1
-1
lines changed

drivers/gpu/drm/amd/display/dc/core/dc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1691,7 +1691,7 @@ bool dc_validate_boot_timing(const struct dc *dc,
16911691
if (crtc_timing->pix_clk_100hz != pix_clk_100hz)
16921692
return false;
16931693

1694-
if (!se->funcs->dp_get_pixel_format)
1694+
if (!se || !se->funcs->dp_get_pixel_format)
16951695
return false;
16961696

16971697
if (!se->funcs->dp_get_pixel_format(

0 commit comments

Comments
 (0)