summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
diff options
context:
space:
mode:
authorAlex Sierra <alex.sierra@amd.com>2020-10-03 21:31:21 +0300
committerAlex Deucher <alexander.deucher@amd.com>2020-10-05 22:13:28 +0300
commit79b1eca0e4acab4c3c71e9563cbbd7ab79e9c70b (patch)
tree0fe2224a7aca88c12a42baeb2126d29c3bff9141 /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
parent2ae78708047026397713a0e4af011bdd5d392e14 (diff)
downloadlinux-79b1eca0e4acab4c3c71e9563cbbd7ab79e9c70b.tar.xz
drm/amdgpu: align frag_end to covered address space
align frag_end to the next pd when there are no page table entries on the current pde. This fixes invalidation of larger address space areas where some page tables are allocated and other aren't. Signed-off-by: Alex Sierra <alex.sierra@amd.com> Signed-off-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/amdgpu_vm.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
index a4efc903349e..2b65e83c808b 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
@@ -1502,6 +1502,8 @@ static int amdgpu_vm_update_ptes(struct amdgpu_vm_update_params *params,
pt = cursor.entry->base.bo;
shift = parent_shift;
+ frag_end = max(frag_end, ALIGN(frag_start + 1,
+ 1ULL << shift));
}
/* Looks good so far, calculate parameters for the update */