aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch')
-rw-r--r--common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch81
1 files changed, 0 insertions, 81 deletions
diff --git a/common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch b/common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch
deleted file mode 100644
index ee3bd53f..00000000
--- a/common/recipes-kernel/linux/files/1047-drm-amdgpu-add-client-id-for-every-vm.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From aa211128f8afccb9a9a5f7ca3c63a9dd64a86c97 Mon Sep 17 00:00:00 2001
-From: Chunming Zhou <David1.Zhou@amd.com>
-Date: Mon, 25 Apr 2016 10:19:13 +0800
-Subject: [PATCH 1047/1110] drm/amdgpu: add client id for every vm
-
-Signed-off-by: Chunming Zhou <David1.Zhou@amd.com>
-Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
-Reviewed-by: Monk Liu <monk.liu@amd.com>
-Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-Signed-off-by: Kalyan Alle <kalyan.alle@amd.com>
----
- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 9 +++++++++
- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 ++--
- 2 files changed, 11 insertions(+), 2 deletions(-)
-
-diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
-index 6079a39..01aab7e 100644
---- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
-+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
-@@ -365,6 +365,7 @@ struct amdgpu_fence_driver {
- /* some special values for the owner field */
- #define AMDGPU_FENCE_OWNER_UNDEFINED ((void*)0ul)
- #define AMDGPU_FENCE_OWNER_VM ((void*)1ul)
-+#define AMDGPU_CLIENT_ID_RESERVED 2
-
- #define AMDGPU_FENCE_FLAG_64BIT (1 << 0)
- #define AMDGPU_FENCE_FLAG_INT (1 << 1)
-@@ -886,6 +887,9 @@ struct amdgpu_vm {
-
- /* Scheduler entity for page table updates */
- struct amd_sched_entity entity;
-+
-+ /* client id */
-+ u64 client_id;
- };
-
- struct amdgpu_vm_id {
-@@ -925,6 +929,8 @@ struct amdgpu_vm_manager {
- struct amdgpu_ring *vm_pte_rings[AMDGPU_MAX_RINGS];
- unsigned vm_pte_num_rings;
- atomic_t vm_pte_next_ring;
-+ /* client id counter */
-+ atomic64_t client_counter;
- };
-
- void amdgpu_vm_manager_init(struct amdgpu_device *adev);
-@@ -988,6 +994,9 @@ struct amdgpu_ctx_ring {
- uint64_t sequence;
- struct fence **fences;
- struct amd_sched_entity entity;
-+
-+ /* client id */
-+ u64 client_id;
- };
-
- struct amdgpu_ctx {
-diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
-index 8650d61..458d3dd 100644
---- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
-+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
-@@ -1393,6 +1393,7 @@ int amdgpu_vm_init(struct amdgpu_device *adev, struct amdgpu_vm *vm)
- for (i = 0; i < AMDGPU_MAX_RINGS; ++i)
- vm->ids[i] = NULL;
- vm->va = RB_ROOT;
-+ vm->client_id = atomic64_inc_return(&adev->vm_manager.client_counter);
- spin_lock_init(&vm->status_lock);
- INIT_LIST_HEAD(&vm->invalidated);
- INIT_LIST_HEAD(&vm->cleared);
-@@ -1516,8 +1517,7 @@ void amdgpu_vm_manager_init(struct amdgpu_device *adev)
- &adev->vm_manager.ids_lru);
- }
-
-- atomic_set(&adev->vm_manager.vm_pte_next_ring, 0);
--
-+ atomic64_set(&adev->vm_manager.client_counter, AMDGPU_CLIENT_ID_RESERVED);
- }
-
- /**
---
-2.7.4
-