aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
diff options
context:
space:
mode:
authorChristian König <[email protected]>2020-01-22 12:38:43 +0000
committerAlex Deucher <[email protected]>2020-02-05 04:30:39 +0000
commit7d28efe0c3c0d14d8c04e15efe8d3d59f12c1049 (patch)
treeb5bdb8aa06b02eba65c1c10a975e543e3e18725f /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
parentdrm/amdgpu: fix parentheses in amdgpu_vm_update_ptes (diff)
downloadkernel-7d28efe0c3c0d14d8c04e15efe8d3d59f12c1049.tar.gz
kernel-7d28efe0c3c0d14d8c04e15efe8d3d59f12c1049.zip
drm/amdgpu: return EINVAL instead of ENOENT in the VM code
That we can't find a PD above the root is expected can only happen if we try to update a larger range than actually managed by the VM. Signed-off-by: Christian König <[email protected]> Tested-by: Tom St Denis <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
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, 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 60da830863da..ca466224b71f 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
@@ -1475,7 +1475,7 @@ static int amdgpu_vm_update_ptes(struct amdgpu_vm_update_params *params,
* shift we should go up one level and check it again.
*/
if (!amdgpu_vm_pt_ancestor(&cursor))
- return -ENOENT;
+ return -EINVAL;
continue;
}