AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/amdgpu: return EINVAL instead of ENOENT in the VM code
@ 2020-01-22 14:03 Christian König
  2020-01-22 14:03 ` [PATCH 2/2] drm/amdgpu: allow higher level PD invalidations Christian König
  2020-01-22 18:11 ` [PATCH 1/2] drm/amdgpu: return EINVAL instead of ENOENT in the VM code Luben Tuikov
  0 siblings, 2 replies; 5+ messages in thread
From: Christian König @ 2020-01-22 14:03 UTC (permalink / raw)
  To: tom.stdenis, amd-gfx

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 <christian.koenig@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
index 5cb182231f5d..8119f32ca94d 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;
 		}
 
-- 
2.14.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-01-22 22:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-01-22 14:03 [PATCH 1/2] drm/amdgpu: return EINVAL instead of ENOENT in the VM code Christian König
2020-01-22 14:03 ` [PATCH 2/2] drm/amdgpu: allow higher level PD invalidations Christian König
2020-01-22 22:22   ` Felix Kuehling
2020-01-22 18:11 ` [PATCH 1/2] drm/amdgpu: return EINVAL instead of ENOENT in the VM code Luben Tuikov
2020-01-22 18:52   ` Christian König

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox