diff options
author | Christian König <christian.koenig@amd.com> | 2016-01-26 06:17:11 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-02-10 14:17:07 -0500 |
commit | 8843dbbbf3460314dab3ef50e9a18c318f8fcdc1 (patch) | |
tree | b934c1da10a1109bb077e3b2c27bb9b98e961ab7 /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |
parent | a1e08d3b838c6a37d60ffcc9b99744a695fad3c9 (diff) |
drm/amdgpu: cleanup comments in VM code
Neither the global nor the local mutex exists any more and
amdgpu doesn't support cayman.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@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 | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 161652bb3d6f..0aa43c5e5377 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |||
@@ -55,7 +55,7 @@ | |||
55 | * | 55 | * |
56 | * @adev: amdgpu_device pointer | 56 | * @adev: amdgpu_device pointer |
57 | * | 57 | * |
58 | * Calculate the number of page directory entries (cayman+). | 58 | * Calculate the number of page directory entries. |
59 | */ | 59 | */ |
60 | static unsigned amdgpu_vm_num_pdes(struct amdgpu_device *adev) | 60 | static unsigned amdgpu_vm_num_pdes(struct amdgpu_device *adev) |
61 | { | 61 | { |
@@ -67,7 +67,7 @@ static unsigned amdgpu_vm_num_pdes(struct amdgpu_device *adev) | |||
67 | * | 67 | * |
68 | * @adev: amdgpu_device pointer | 68 | * @adev: amdgpu_device pointer |
69 | * | 69 | * |
70 | * Calculate the size of the page directory in bytes (cayman+). | 70 | * Calculate the size of the page directory in bytes. |
71 | */ | 71 | */ |
72 | static unsigned amdgpu_vm_directory_size(struct amdgpu_device *adev) | 72 | static unsigned amdgpu_vm_directory_size(struct amdgpu_device *adev) |
73 | { | 73 | { |
@@ -155,8 +155,6 @@ void amdgpu_vm_move_pt_bos_in_lru(struct amdgpu_device *adev, | |||
155 | * @fence: fence protecting ID from reuse | 155 | * @fence: fence protecting ID from reuse |
156 | * | 156 | * |
157 | * Allocate an id for the vm, adding fences to the sync obj as necessary. | 157 | * Allocate an id for the vm, adding fences to the sync obj as necessary. |
158 | * | ||
159 | * Global mutex must be locked! | ||
160 | */ | 158 | */ |
161 | int amdgpu_vm_grab_id(struct amdgpu_vm *vm, struct amdgpu_ring *ring, | 159 | int amdgpu_vm_grab_id(struct amdgpu_vm *vm, struct amdgpu_ring *ring, |
162 | struct amdgpu_sync *sync, struct fence *fence) | 160 | struct amdgpu_sync *sync, struct fence *fence) |
@@ -216,9 +214,7 @@ int amdgpu_vm_grab_id(struct amdgpu_vm *vm, struct amdgpu_ring *ring, | |||
216 | * @vm: vm we want to flush | 214 | * @vm: vm we want to flush |
217 | * @updates: last vm update that we waited for | 215 | * @updates: last vm update that we waited for |
218 | * | 216 | * |
219 | * Flush the vm (cayman+). | 217 | * Flush the vm. |
220 | * | ||
221 | * Global and local mutex must be locked! | ||
222 | */ | 218 | */ |
223 | void amdgpu_vm_flush(struct amdgpu_ring *ring, | 219 | void amdgpu_vm_flush(struct amdgpu_ring *ring, |
224 | struct amdgpu_vm *vm, | 220 | struct amdgpu_vm *vm, |
@@ -253,7 +249,7 @@ void amdgpu_vm_flush(struct amdgpu_ring *ring, | |||
253 | * @vm: requested vm | 249 | * @vm: requested vm |
254 | * @bo: requested buffer object | 250 | * @bo: requested buffer object |
255 | * | 251 | * |
256 | * Find @bo inside the requested vm (cayman+). | 252 | * Find @bo inside the requested vm. |
257 | * Search inside the @bos vm list for the requested vm | 253 | * Search inside the @bos vm list for the requested vm |
258 | * Returns the found bo_va or NULL if none is found | 254 | * Returns the found bo_va or NULL if none is found |
259 | * | 255 | * |
@@ -425,10 +421,8 @@ uint64_t amdgpu_vm_map_gart(const dma_addr_t *pages_addr, uint64_t addr) | |||
425 | * @end: end of GPU address range | 421 | * @end: end of GPU address range |
426 | * | 422 | * |
427 | * Allocates new page tables if necessary | 423 | * Allocates new page tables if necessary |
428 | * and updates the page directory (cayman+). | 424 | * and updates the page directory. |
429 | * Returns 0 for success, error for failure. | 425 | * Returns 0 for success, error for failure. |
430 | * | ||
431 | * Global and local mutex must be locked! | ||
432 | */ | 426 | */ |
433 | int amdgpu_vm_update_page_directory(struct amdgpu_device *adev, | 427 | int amdgpu_vm_update_page_directory(struct amdgpu_device *adev, |
434 | struct amdgpu_vm *vm) | 428 | struct amdgpu_vm *vm) |
@@ -538,8 +532,6 @@ error_free: | |||
538 | * @pe_end: last PTE to handle | 532 | * @pe_end: last PTE to handle |
539 | * @addr: addr those PTEs should point to | 533 | * @addr: addr those PTEs should point to |
540 | * @flags: hw mapping flags | 534 | * @flags: hw mapping flags |
541 | * | ||
542 | * Global and local mutex must be locked! | ||
543 | */ | 535 | */ |
544 | static void amdgpu_vm_frag_ptes(struct amdgpu_device *adev, | 536 | static void amdgpu_vm_frag_ptes(struct amdgpu_device *adev, |
545 | struct amdgpu_gart *gtt, | 537 | struct amdgpu_gart *gtt, |
@@ -620,9 +612,7 @@ static void amdgpu_vm_frag_ptes(struct amdgpu_device *adev, | |||
620 | * @dst: destination address to map to | 612 | * @dst: destination address to map to |
621 | * @flags: mapping flags | 613 | * @flags: mapping flags |
622 | * | 614 | * |
623 | * Update the page tables in the range @start - @end (cayman+). | 615 | * Update the page tables in the range @start - @end. |
624 | * | ||
625 | * Global and local mutex must be locked! | ||
626 | */ | 616 | */ |
627 | static void amdgpu_vm_update_ptes(struct amdgpu_device *adev, | 617 | static void amdgpu_vm_update_ptes(struct amdgpu_device *adev, |
628 | struct amdgpu_gart *gtt, | 618 | struct amdgpu_gart *gtt, |
@@ -1005,7 +995,7 @@ int amdgpu_vm_clear_invalids(struct amdgpu_device *adev, | |||
1005 | * @vm: requested vm | 995 | * @vm: requested vm |
1006 | * @bo: amdgpu buffer object | 996 | * @bo: amdgpu buffer object |
1007 | * | 997 | * |
1008 | * Add @bo into the requested vm (cayman+). | 998 | * Add @bo into the requested vm. |
1009 | * Add @bo to the list of bos associated with the vm | 999 | * Add @bo to the list of bos associated with the vm |
1010 | * Returns newly added bo_va or NULL for failure | 1000 | * Returns newly added bo_va or NULL for failure |
1011 | * | 1001 | * |
@@ -1237,7 +1227,7 @@ int amdgpu_vm_bo_unmap(struct amdgpu_device *adev, | |||
1237 | * @adev: amdgpu_device pointer | 1227 | * @adev: amdgpu_device pointer |
1238 | * @bo_va: requested bo_va | 1228 | * @bo_va: requested bo_va |
1239 | * | 1229 | * |
1240 | * Remove @bo_va->bo from the requested vm (cayman+). | 1230 | * Remove @bo_va->bo from the requested vm. |
1241 | * | 1231 | * |
1242 | * Object have to be reserved! | 1232 | * Object have to be reserved! |
1243 | */ | 1233 | */ |
@@ -1282,7 +1272,7 @@ void amdgpu_vm_bo_rmv(struct amdgpu_device *adev, | |||
1282 | * @vm: requested vm | 1272 | * @vm: requested vm |
1283 | * @bo: amdgpu buffer object | 1273 | * @bo: amdgpu buffer object |
1284 | * | 1274 | * |
1285 | * Mark @bo as invalid (cayman+). | 1275 | * Mark @bo as invalid. |
1286 | */ | 1276 | */ |
1287 | void amdgpu_vm_bo_invalidate(struct amdgpu_device *adev, | 1277 | void amdgpu_vm_bo_invalidate(struct amdgpu_device *adev, |
1288 | struct amdgpu_bo *bo) | 1278 | struct amdgpu_bo *bo) |
@@ -1303,7 +1293,7 @@ void amdgpu_vm_bo_invalidate(struct amdgpu_device *adev, | |||
1303 | * @adev: amdgpu_device pointer | 1293 | * @adev: amdgpu_device pointer |
1304 | * @vm: requested vm | 1294 | * @vm: requested vm |
1305 | * | 1295 | * |
1306 | * Init @vm fields (cayman+). | 1296 | * Init @vm fields. |
1307 | */ | 1297 | */ |
1308 | int amdgpu_vm_init(struct amdgpu_device *adev, struct amdgpu_vm *vm) | 1298 | int amdgpu_vm_init(struct amdgpu_device *adev, struct amdgpu_vm *vm) |
1309 | { | 1299 | { |
@@ -1364,7 +1354,7 @@ int amdgpu_vm_init(struct amdgpu_device *adev, struct amdgpu_vm *vm) | |||
1364 | * @adev: amdgpu_device pointer | 1354 | * @adev: amdgpu_device pointer |
1365 | * @vm: requested vm | 1355 | * @vm: requested vm |
1366 | * | 1356 | * |
1367 | * Tear down @vm (cayman+). | 1357 | * Tear down @vm. |
1368 | * Unbind the VM and remove all bos from the vm bo list | 1358 | * Unbind the VM and remove all bos from the vm bo list |
1369 | */ | 1359 | */ |
1370 | void amdgpu_vm_fini(struct amdgpu_device *adev, struct amdgpu_vm *vm) | 1360 | void amdgpu_vm_fini(struct amdgpu_device *adev, struct amdgpu_vm *vm) |