diff options
| author | Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com> | 2026-01-09 15:26:36 -0500 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2026-02-03 17:24:21 -0500 |
| commit | 6b61a54e684006ca0d92d684a1d3c3a00f077d8f (patch) | |
| tree | 4127f442c5eda13f15fe4c4297c914ae4f08039e /include/uapi/linux | |
| parent | 84962445cd8a83dc5bed4c8ad5bbb2c1cdb249a0 (diff) | |
drm/amdgpu: Fix double deletion of validate_list
If amdgpu_amdkfd_gpuvm_free_memory_of_gpu() fails after kgd_mem is
removed from validate_list, the mem handle still lingers in the KFD idr.
This means when process is terminated,
kfd_process_free_outstanding_kfd_bos() will call
amdgpu_amdkfd_gpuvm_free_memory_of_gpu() again resulting in double
deletion.
To avoid this -
(a) Check if list is empty before deleting it
(b) Rearragne amdgpu_amdkfd_gpuvm_free_memory_of_gpu() such that it can
be safely called again if it returns failure the first time.
Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Reviewed-by: Philip Yang <Philip.Yang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 6ba60345f45eaf7cb4f89105d26083a4b9fd1cba)
Diffstat (limited to 'include/uapi/linux')
0 files changed, 0 insertions, 0 deletions
