summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSunil Khatri <sunil.khatri@amd.com>2026-10-12 14:17:52 +0530
committerAlex Deucher <alexander.deucher@amd.com>2026-10-15 12:02:51 -0400
commitfb1977f2d205a7e64fbbabe76e239953584bdc3f (patch)
treeea27d3546f3559950f382eca1d6df90dd749a3cd
parented73c946979771f050f05d7f00cbe9b7afd04059 (diff)
downloadlinux-next-fb1977f2d205a7e64fbbabe76e239953584bdc3f.tar.gz
linux-next-fb1977f2d205a7e64fbbabe76e239953584bdc3f.zip
drm/amdgpu: reserve SPM VMID on gfx8
Set vm_manager.spm_vmid to the top GFXHUB VMID so the SPM reservation path hands out a fixed, isolated VMID on gfx8 instead of borrowing one from the graphics pool. Signed-off-by: Sunil Khatri <sunil.khatri@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r--drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
index 3f9ec7427319..15592027e7c0 100644
--- a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
@@ -1123,6 +1123,10 @@ static int gmc_v8_0_sw_init(struct amdgpu_ip_block *ip_block)
* amdkfd/MES user queues will use VMIDs 8-15
*/
vmid_mask = GENMASK(7, 1);
+
+ /* Reserve the last VMID for SPM */
+ adev->vm_manager.spm_vmid = AMDGPU_NUM_VMID - 1;
+
amdgpu_vmid_mgr_set_vmid_mask(adev, vmid_mask, vmid_mask);
amdgpu_vm_manager_init(adev);