diff options
author | Christian König <christian.koenig@amd.com> | 2018-01-03 07:36:22 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2018-01-10 15:44:54 -0500 |
commit | 9b8cad2047ddcce761b0665ba7e601228df82bfd (patch) | |
tree | bc8791436833655646524bf8e2f5a7347701dcc6 /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |
parent | 3cc1d3ea4a6a81a7108fe27fa42efd86ea64061d (diff) |
drm/amdgpu: optimize moved handling only when vm_debug is inactive
Otherwise we would completely circumvent that debugging feature.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Roger He <Hongbo.He@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 |
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 81505870eebc..cd1752b6afa9 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |||
@@ -1685,7 +1685,7 @@ int amdgpu_vm_handle_moved(struct amdgpu_device *adev, | |||
1685 | if (resv == vm->root.base.bo->tbo.resv) | 1685 | if (resv == vm->root.base.bo->tbo.resv) |
1686 | clear = false; | 1686 | clear = false; |
1687 | /* Try to reserve the BO to avoid clearing its ptes */ | 1687 | /* Try to reserve the BO to avoid clearing its ptes */ |
1688 | else if (reservation_object_trylock(resv)) | 1688 | else if (!amdgpu_vm_debug && reservation_object_trylock(resv)) |
1689 | clear = false; | 1689 | clear = false; |
1690 | /* Somebody else is using the BO right now */ | 1690 | /* Somebody else is using the BO right now */ |
1691 | else | 1691 | else |