From: Christian König Date: Fri, 5 Jun 2015 18:56:17 +0000 (+0200) Subject: drm/amdgpu: fix saddr handling in amdgpu_vm_bo_unmap X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=6c7fc503a47f9b87dfd7c76e34f808ab6870a82f;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git drm/amdgpu: fix saddr handling in amdgpu_vm_bo_unmap Signed-off-by: Christian König Reviewed-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 33696ee55349..407882b233c7 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c @@ -1084,6 +1084,8 @@ int amdgpu_vm_bo_unmap(struct amdgpu_device *adev, struct amdgpu_bo_va_mapping *mapping; struct amdgpu_vm *vm = bo_va->vm; + saddr /= AMDGPU_GPU_PAGE_SIZE; + list_for_each_entry(mapping, &bo_va->mappings, list) { if (mapping->it.start == saddr) break;