diff options
author | 2020-12-08 11:14:53 +0100 | |
---|---|---|
committer | 2020-12-08 23:05:40 -0500 | |
commit | 68fce5f07c304b34531dd9d7e13f6d174922e4c4 (patch) | |
tree | 6b1650101b13c6f23a6780a3ce4e3a09a4dd4134 /drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c | |
parent | drm/amdgpu: fix sdma instance fw version and feature version init (diff) | |
download | linux-68fce5f07c304b34531dd9d7e13f6d174922e4c4.tar.gz linux-68fce5f07c304b34531dd9d7e13f6d174922e4c4.tar.bz2 linux-68fce5f07c304b34531dd9d7e13f6d174922e4c4.zip |
drm/amdgpu: use AMDGPU_NUM_VMID when possible
Replace hardcoded vmid number with AMDGPU_NUM_VMID macro.
Signed-off-by: Nirmoy Das <nirmoy.das@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c b/drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c index fa77eae6cf47..b72c8e4ca36b 100644 --- a/drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c +++ b/drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c @@ -376,7 +376,7 @@ static void mmhub_v2_3_gart_disable(struct amdgpu_device *adev) u32 i; /* Disable all tables */ - for (i = 0; i < 16; i++) + for (i = 0; i < AMDGPU_NUM_VMID; i++) WREG32_SOC15_OFFSET(MMHUB, 0, mmMMVM_CONTEXT0_CNTL, i * hub->ctx_distance, 0); |