summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2018-04-19 10:56:02 +0200
committerAlex Deucher <alexander.deucher@amd.com>2018-05-24 10:07:52 -0500
commitaf4c0f650b563c7b30c1d8cd2bb926247ceb19cc (patch)
tree92238b98187bcf270b5b8b269bd93a16f67af695 /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h
parent22cc6c5e1958e5a08b4c44203d1810ab07ce5a16 (diff)
downloadop-kernel-dev-af4c0f650b563c7b30c1d8cd2bb926247ceb19cc.zip
op-kernel-dev-af4c0f650b563c7b30c1d8cd2bb926247ceb19cc.tar.gz
drm/amdgpu: rework VM state machine lock handling v2
Only the moved state needs a separate spin lock protection. All other states are protected by reserving the VM anyway. v2: fix some more incorrect cases Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h
index d682708..0196b9a 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h
@@ -168,9 +168,6 @@ struct amdgpu_vm {
/* tree of virtual addresses mapped */
struct rb_root_cached va;
- /* protecting invalidated */
- spinlock_t status_lock;
-
/* BOs who needs a validation */
struct list_head evicted;
@@ -179,6 +176,7 @@ struct amdgpu_vm {
/* BOs moved, but not yet updated in the PT */
struct list_head moved;
+ spinlock_t moved_lock;
/* BO mappings freed, but not yet updated in the PT */
struct list_head freed;
OpenPOWER on IntegriCloud