Skip to content

Commit 597eb70

Browse files
PhilipYangAalexdeucher
authored andcommitted
drm/amdkfd: Don't clear PT after process killed
If process is killed. the vm entity is stopped, submit pt update job will trigger the error message "*ERROR* Trying to push to a killed entity", job will not execute. Suggested-by: Christian König <christian.koenig@amd.com> Signed-off-by: Philip Yang <Philip.Yang@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 10c382ec6c6d1e11975a11962bec21cba6360391) Cc: stable@vger.kernel.org
1 parent 7c5609b commit 597eb70

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1267,6 +1267,10 @@ static int unmap_bo_from_gpuvm(struct kgd_mem *mem,
12671267

12681268
(void)amdgpu_vm_bo_unmap(adev, bo_va, entry->va);
12691269

1270+
/* VM entity stopped if process killed, don't clear freed pt bo */
1271+
if (!amdgpu_vm_ready(vm))
1272+
return 0;
1273+
12701274
(void)amdgpu_vm_clear_freed(adev, vm, &bo_va->last_pt_update);
12711275

12721276
(void)amdgpu_sync_fence(sync, bo_va->last_pt_update, GFP_KERNEL);

0 commit comments

Comments
 (0)