diff options
| author | Srinivasan Shanmugam <[email protected]> | 2024-07-31 07:39:28 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2024-08-06 14:44:04 +0000 |
| commit | 62ed6f0f198da04e884062264df308277628004f (patch) | |
| tree | e9eec304e0baedd14c223748761e243872e585ef /drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | |
| parent | drm/amdgpu: use CPU for page table update if SDMA is unavailable (diff) | |
| download | kernel-62ed6f0f198da04e884062264df308277628004f.tar.gz kernel-62ed6f0f198da04e884062264df308277628004f.zip | |
drm/amd/display: Add NULL check for function pointer in dcn20_set_output_transfer_func
This commit adds a null check for the set_output_gamma function pointer
in the dcn20_set_output_transfer_func function. Previously,
set_output_gamma was being checked for null at line 1030, but then it
was being dereferenced without any null check at line 1048. This could
potentially lead to a null pointer dereference error if set_output_gamma
is null.
To fix this, we now ensure that set_output_gamma is not null before
dereferencing it. We do this by adding a null check for set_output_gamma
before the call to set_output_gamma at line 1048.
Cc: Tom Chung <[email protected]>
Cc: Rodrigo Siqueira <[email protected]>
Cc: Roman Li <[email protected]>
Cc: Alex Hung <[email protected]>
Cc: Aurabindo Pillai <[email protected]>
Cc: Harry Wentland <[email protected]>
Cc: Hamza Mahfooz <[email protected]>
Signed-off-by: Srinivasan Shanmugam <[email protected]>
Reviewed-by: Tom Chung <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c')
0 files changed, 0 insertions, 0 deletions
