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>
This commit is contained in:
Alex Sierra 2020-10-03 13:31:21 -05:00 committed by Alex Deucher
parent 2ae7870804
commit 79b1eca0e4
1 changed files with 2 additions and 0 deletions

View File

@ -1502,6 +1502,8 @@ static int amdgpu_vm_update_ptes(struct amdgpu_vm_update_params *params,
pt = cursor.entry->base.bo; pt = cursor.entry->base.bo;
shift = parent_shift; shift = parent_shift;
frag_end = max(frag_end, ALIGN(frag_start + 1,
1ULL << shift));
} }
/* Looks good so far, calculate parameters for the update */ /* Looks good so far, calculate parameters for the update */