diff options
| author | Alex Hung <[email protected]> | 2024-07-15 16:37:28 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2024-07-27 21:31:59 +0000 |
| commit | 58a8ee96f84d2c21abb85ad8c22d2bbdf59bd7a9 (patch) | |
| tree | f4c6763ee15fb6461ffbdeb9cb181ebfde8f9bae | |
| parent | drm/amd/display: Check null pointers before using them (diff) | |
| download | kernel-58a8ee96f84d2c21abb85ad8c22d2bbdf59bd7a9.tar.gz kernel-58a8ee96f84d2c21abb85ad8c22d2bbdf59bd7a9.zip | |
drm/amd/display: Check stream_status before it is used
[WHAT & HOW]
dc_state_get_stream_status can return null, and therefore null must be
checked before stream_status is used.
This fixes 1 NULL_RETURNS issue reported by Coverity.
Signed-off-by: Alex Hung <[email protected]>
Reviewed-by: Rodrigo Siqueira <[email protected]>
Tested-by: Daniel Wheeler <[email protected]>
Signed-off-by: Rodrigo Siqueira <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
| -rw-r--r-- | drivers/gpu/drm/amd/display/dc/core/dc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c index 95d6e29d5e47..4c9e420742a2 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc.c @@ -3748,7 +3748,7 @@ static void commit_planes_for_stream_fast(struct dc *dc, surface_count, stream, context); - } else { + } else if (stream_status) { build_dmub_cmd_list(dc, srf_updates, surface_count, |
