]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/amdgpu: Fix NULL ptr dereference issue for non userq fences
authorArunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com>
Mon, 9 Dec 2024 17:32:28 +0000 (23:02 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 8 Apr 2025 20:48:19 +0000 (16:48 -0400)
commitc9e20cb005fdb6a727dc1a85d7192a35eeb11987
tree9b3620777f59f7f2ccf2be07fb2004d648323c31
parent9ed335d9398475675e26fcf92d7cf956e5b8a605
drm/amdgpu: Fix NULL ptr dereference issue for non userq fences

Add the correct fences count variable [num_fences] in the fences
array iteration to handle the userq / non-userq fences.

v2:(Christian)
  - All fences in the array either come from some reservation object
    or drm_syncobj. If any of those are NULL then there is a bug
    somewhere else.

Signed-off-by: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_userq_fence.c