mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-10 20:48:12 +00:00
drm/amdgpu: reserve root PD fence slots for userq eviction-fence rearm
Root cause: - In userq restore/rearm, root PD was locked with amdgpu_vm_lock_pd(vm, &exec, 1). - Later in the same drm_exec context, amdgpu_evf_mgr_rearm() attaches BOOKKEEP eviction fences to all locked BOs. - In this flow, root PD validation/update can also consume move-fence slots, so reserving only +1 at PD lock time is not sufficient under stress. Fix: - Reserve caller-side slots at the actual source by switching to: amdgpu_vm_lock_pd(vm, &exec, TTM_NUM_MOVE_FENCES + 1) This keeps reservation policy in callers, consistent with Christian Konig feedback and with amdgpu_gem_object_open() where callers reserve TTM_NUM_MOVE_FENCES + 1 before attaching eviction fences. Credit: - Christian Konig: confirmed fence-slot reservation belongs to callers and asked to investigate why +1 was still not enough. - Prike Liang: clarified the initial variant was workaround-only and developed that initial version independently. Cc: Prike Liang <prike.liang@amd.com> Cc: Sunil Khatri <sunil.khatri@amd.com> Cc: Christian König <christian.koenig@amd.com> Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Vitaly Prosyak <vitaly.prosyak@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
5e6b21bce9
commit
a2a2774535
1 changed files with 5 additions and 1 deletions
Loading…
Add table
Add a link
Reference in a new issue