aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChunming Zhou <[email protected]>2017-12-11 15:55:03 +0800
committerAlex Deucher <[email protected]>2017-12-13 17:31:01 -0500
commitc4c3351783cb1758801a5928c98b0dcb2074c082 (patch)
treed91051617603586f6767250e7a46e419968c5f14
parent44da0d57db175b02f36a2ecf3c9b89cf24a476c4 (diff)
drm/amdgpu: fix huge page setting for ATS case
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
index 68039ad3c8e0..709587d8a77f 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
@@ -343,7 +343,7 @@ static int amdgpu_vm_alloc_levels(struct amdgpu_device *adev,
if (vm->pte_support_ats) {
init_value = AMDGPU_PTE_DEFAULT_ATC;
- if (level != adev->vm_manager.num_level - 1)
+ if (level != adev->vm_manager.num_level)
init_value |= AMDGPU_PDE_PTE;
}