Commit 3e3e53f8 authored by Alex Deucher's avatar Alex Deucher

drm/radeon/vm: only align the pt base to 32k

fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=67016Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
parent 745a39a9
...@@ -466,7 +466,7 @@ int radeon_vm_manager_init(struct radeon_device *rdev) ...@@ -466,7 +466,7 @@ int radeon_vm_manager_init(struct radeon_device *rdev)
size += rdev->vm_manager.max_pfn * 8; size += rdev->vm_manager.max_pfn * 8;
size *= 2; size *= 2;
r = radeon_sa_bo_manager_init(rdev, &rdev->vm_manager.sa_manager, r = radeon_sa_bo_manager_init(rdev, &rdev->vm_manager.sa_manager,
RADEON_VM_PTB_ALIGN(size), RADEON_GPU_PAGE_ALIGN(size),
RADEON_VM_PTB_ALIGN_SIZE, RADEON_VM_PTB_ALIGN_SIZE,
RADEON_GEM_DOMAIN_VRAM); RADEON_GEM_DOMAIN_VRAM);
if (r) { if (r) {
...@@ -621,7 +621,7 @@ int radeon_vm_alloc_pt(struct radeon_device *rdev, struct radeon_vm *vm) ...@@ -621,7 +621,7 @@ int radeon_vm_alloc_pt(struct radeon_device *rdev, struct radeon_vm *vm)
} }
retry: retry:
pd_size = RADEON_VM_PTB_ALIGN(radeon_vm_directory_size(rdev)); pd_size = radeon_vm_directory_size(rdev);
r = radeon_sa_bo_new(rdev, &rdev->vm_manager.sa_manager, r = radeon_sa_bo_new(rdev, &rdev->vm_manager.sa_manager,
&vm->page_directory, pd_size, &vm->page_directory, pd_size,
RADEON_VM_PTB_ALIGN_SIZE, false); RADEON_VM_PTB_ALIGN_SIZE, false);
...@@ -953,8 +953,8 @@ static int radeon_vm_update_pdes(struct radeon_device *rdev, ...@@ -953,8 +953,8 @@ static int radeon_vm_update_pdes(struct radeon_device *rdev,
retry: retry:
r = radeon_sa_bo_new(rdev, &rdev->vm_manager.sa_manager, r = radeon_sa_bo_new(rdev, &rdev->vm_manager.sa_manager,
&vm->page_tables[pt_idx], &vm->page_tables[pt_idx],
RADEON_VM_PTB_ALIGN(RADEON_VM_PTE_COUNT * 8), RADEON_VM_PTE_COUNT * 8,
RADEON_VM_PTB_ALIGN_SIZE, false); RADEON_GPU_PAGE_SIZE, false);
if (r == -ENOMEM) { if (r == -ENOMEM) {
r = radeon_vm_evict(rdev, vm); r = radeon_vm_evict(rdev, vm);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment