diff options
| author | Siyang Liu <[email protected]> | 2025-07-04 03:16:22 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2025-08-04 19:44:55 +0000 |
| commit | 1bcf63a44381691d6192872801f830ce3250e367 (patch) | |
| tree | e71bdfd75c2f11b8587f9ecb2dabcbb0c5e1d5e6 /drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | |
| parent | drm/amd/display: Add primary plane to commits for correct VRR handling (diff) | |
| download | kernel-1bcf63a44381691d6192872801f830ce3250e367.tar.gz kernel-1bcf63a44381691d6192872801f830ce3250e367.zip | |
drm/amd/display: fix a Null pointer dereference vulnerability
[Why]
A null pointer dereference vulnerability exists in the AMD display driver's
(DC module) cleanup function dc_destruct().
When display control context (dc->ctx) construction fails
(due to memory allocation failure), this pointer remains NULL.
During subsequent error handling when dc_destruct() is called,
there's no NULL check before dereferencing the perf_trace member
(dc->ctx->perf_trace), causing a kernel null pointer dereference crash.
[How]
Check if dc->ctx is non-NULL before dereferencing.
Link: https://lore.kernel.org/r/[email protected]
Co-developed-by: Mario Limonciello <[email protected]>
Signed-off-by: Mario Limonciello <[email protected]>
(Updated commit text and removed unnecessary error message)
Signed-off-by: Siyang Liu <[email protected]>
Signed-off-by: Roman Li <[email protected]>
Reviewed-by: Alex Hung <[email protected]>
Tested-by: Daniel Wheeler <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
(cherry picked from commit 9dd8e2ba268c636c240a918e0a31e6feaee19404)
Cc: [email protected]
Diffstat (limited to 'drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c')
0 files changed, 0 insertions, 0 deletions
