]> git.karo-electronics.de Git - linux-beck.git/commitdiff
drm/ttm: remove no_gpu_wait param from ttm_bo_move_accel_cleanup
authorChristian König <christian.koenig@amd.com>
Wed, 15 Jun 2016 11:44:00 +0000 (13:44 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 7 Jul 2016 18:54:39 +0000 (14:54 -0400)
It isn't used and not waiting for the GPU after scheduling a move is
actually quite dangerous.

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
drivers/gpu/drm/nouveau/nouveau_bo.c
drivers/gpu/drm/radeon/radeon_ttm.c
drivers/gpu/drm/ttm/ttm_bo_util.c
include/drm/ttm/ttm_bo_driver.h

index 232f12344f7966a2e7f7d1b0326d16e639f9a0bf..b2b9df6686c8b24755544ee72c9933edc59cf2cf 100644 (file)
@@ -287,8 +287,7 @@ static int amdgpu_move_blit(struct ttm_buffer_object *bo,
                               new_mem->num_pages * PAGE_SIZE, /* bytes */
                               bo->resv, &fence);
        /* FIXME: handle copy error */
-       r = ttm_bo_move_accel_cleanup(bo, fence,
-                                     evict, no_wait_gpu, new_mem);
+       r = ttm_bo_move_accel_cleanup(bo, fence, evict, new_mem);
        fence_put(fence);
        return r;
 }
index 4fb1bf9b81b3366c891ea636163eb07335ba6ec3..cdd551ef5bc8d221d8b2e2e33fcb6479e72ade2f 100644 (file)
@@ -1082,7 +1082,6 @@ nouveau_bo_move_m2mf(struct ttm_buffer_object *bo, int evict, bool intr,
                                ret = ttm_bo_move_accel_cleanup(bo,
                                                                &fence->base,
                                                                evict,
-                                                               no_wait_gpu,
                                                                new_mem);
                                nouveau_fence_unref(&fence);
                        }
index 20ca22dc681366403094c6e3de29b26edb61e0f1..ffdad81ef9647cbc96612e3d0dc4d41b85009dff 100644 (file)
@@ -300,8 +300,7 @@ static int radeon_move_blit(struct ttm_buffer_object *bo,
        if (IS_ERR(fence))
                return PTR_ERR(fence);
 
-       r = ttm_bo_move_accel_cleanup(bo, &fence->base,
-                                     evict, no_wait_gpu, new_mem);
+       r = ttm_bo_move_accel_cleanup(bo, &fence->base, evict, new_mem);
        radeon_fence_unref(&fence);
        return r;
 }
index 434f2394ad2c1d029ca6ea041602c660446a504e..c8fe554ee1c72bb00baa4fe2a536ea07453ebead 100644 (file)
@@ -637,7 +637,6 @@ EXPORT_SYMBOL(ttm_bo_kunmap);
 int ttm_bo_move_accel_cleanup(struct ttm_buffer_object *bo,
                              struct fence *fence,
                              bool evict,
-                             bool no_wait_gpu,
                              struct ttm_mem_reg *new_mem)
 {
        struct ttm_bo_device *bdev = bo->bdev;
index 0d1d9d78c650669469adc864008073aa64c49dd9..697e5f919135e71a3c716432eba9d8d8aeac38e2 100644 (file)
@@ -1004,7 +1004,6 @@ extern void ttm_bo_free_old_node(struct ttm_buffer_object *bo);
  * @bo: A pointer to a struct ttm_buffer_object.
  * @fence: A fence object that signals when moving is complete.
  * @evict: This is an evict move. Don't return until the buffer is idle.
- * @no_wait_gpu: Return immediately if the GPU is busy.
  * @new_mem: struct ttm_mem_reg indicating where to move.
  *
  * Accelerated move function to be called when an accelerated move
@@ -1016,8 +1015,7 @@ extern void ttm_bo_free_old_node(struct ttm_buffer_object *bo);
  */
 
 extern int ttm_bo_move_accel_cleanup(struct ttm_buffer_object *bo,
-                                    struct fence *fence,
-                                    bool evict, bool no_wait_gpu,
+                                    struct fence *fence, bool evict,
                                     struct ttm_mem_reg *new_mem);
 /**
  * ttm_io_prot