linux/drivers/gpu/drm/amd
Alex Deucher 5539bc82ce drm/amdgpu: fix a memory leak in fence cleanup when unloading
commit 7838fb5f11 upstream.

Commit b61badd20b ("drm/amdgpu: fix usage slab after free")
reordered when amdgpu_fence_driver_sw_fini() was called after
that patch, amdgpu_fence_driver_sw_fini() effectively became
a no-op as the sched entities we never freed because the
ring pointers were already set to NULL.  Remove the NULL
setting.

Reported-by: Lin.Cao <lincao12@amd.com>
Cc: Vitaly Prosyak <vitaly.prosyak@amd.com>
Cc: Christian König <christian.koenig@amd.com>
Fixes: b61badd20b ("drm/amdgpu: fix usage slab after free")
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit a525fa37aa)
Cc: stable@vger.kernel.org
[ Adapt to conditional check ]
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-09-19 16:35:51 +02:00
..
acp drivers/gpu: Fix misalignment in comment block 2024-05-29 14:48:30 -04:00
amdgpu drm/amdgpu: fix a memory leak in fence cleanup when unloading 2025-09-19 16:35:51 +02:00
amdkfd drm/amdkfd: Destroy KFD debugfs after destroy KFD wq 2025-08-28 16:31:02 +02:00
amdxcp drm/amd/amdxcp: Fix warnings 2024-05-08 15:17:05 -04:00
display drm/amd/display: use udelay rather than fsleep 2025-09-19 16:35:49 +02:00
include drm/amdgpu: Set snoop bit for SDMA for MI series 2025-05-29 11:02:52 +02:00
pm drm/amd/amdgpu: disable hwmon power1_cap* for gfx 11.0.3 on vf mode 2025-09-04 15:31:55 +02:00