summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2026-01-22 17:27:25 +0300
committerAlex Deucher <alexander.deucher@amd.com>2026-03-17 17:33:39 +0300
commit98dc529a27c57e184ab47453993ba9cfcfcec0ca (patch)
tree4380acb06c318afb295cac73fce5f6237ce8c0f0
parent688b87d39e0aa8135105b40dc167d74b5ada5332 (diff)
downloadlinux-98dc529a27c57e184ab47453993ba9cfcfcec0ca.tar.xz
drm/amdgpu: fix amdgpu_userq_evict
Canceling the resume worker synchonized can deadlock because it can in turn wait for the eviction worker through the userq_mutex. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Sunil Khatri <sunil.khatri@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
index 7cdff206e7f3..5619233e1b68 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
@@ -1331,13 +1331,8 @@ amdgpu_userq_evict(struct amdgpu_userq_mgr *uq_mgr,
/* Signal current eviction fence */
amdgpu_eviction_fence_signal(evf_mgr, ev_fence);
- if (evf_mgr->fd_closing) {
- cancel_delayed_work_sync(&uq_mgr->resume_work);
- return;
- }
-
- /* Schedule a resume work */
- schedule_delayed_work(&uq_mgr->resume_work, 0);
+ if (!evf_mgr->fd_closing)
+ schedule_delayed_work(&uq_mgr->resume_work, 0);
}
int amdgpu_userq_mgr_init(struct amdgpu_userq_mgr *userq_mgr, struct drm_file *file_priv,