aboutsummaryrefslogtreecommitdiffstats
path: root/include/drm/ttm/ttm_bo_driver.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/drm/ttm/ttm_bo_driver.h')
-rw-r--r--include/drm/ttm/ttm_bo_driver.h29
1 files changed, 18 insertions, 11 deletions
diff --git a/include/drm/ttm/ttm_bo_driver.h b/include/drm/ttm/ttm_bo_driver.h
index e929c27ede22..69f70e418c2c 100644
--- a/include/drm/ttm/ttm_bo_driver.h
+++ b/include/drm/ttm/ttm_bo_driver.h
@@ -311,7 +311,8 @@ struct ttm_bo_driver {
311 */ 311 */
312 int (*move) (struct ttm_buffer_object *bo, 312 int (*move) (struct ttm_buffer_object *bo,
313 bool evict, bool interruptible, 313 bool evict, bool interruptible,
314 bool no_wait, struct ttm_mem_reg *new_mem); 314 bool no_wait_reserve, bool no_wait_gpu,
315 struct ttm_mem_reg *new_mem);
315 316
316 /** 317 /**
317 * struct ttm_bo_driver_member verify_access 318 * struct ttm_bo_driver_member verify_access
@@ -633,7 +634,8 @@ extern bool ttm_mem_reg_is_pci(struct ttm_bo_device *bdev,
633 * @proposed_placement: Proposed new placement for the buffer object. 634 * @proposed_placement: Proposed new placement for the buffer object.
634 * @mem: A struct ttm_mem_reg. 635 * @mem: A struct ttm_mem_reg.
635 * @interruptible: Sleep interruptible when sliping. 636 * @interruptible: Sleep interruptible when sliping.
636 * @no_wait: Don't sleep waiting for space to become available. 637 * @no_wait_reserve: Return immediately if other buffers are busy.
638 * @no_wait_gpu: Return immediately if the GPU is busy.
637 * 639 *
638 * Allocate memory space for the buffer object pointed to by @bo, using 640 * Allocate memory space for the buffer object pointed to by @bo, using
639 * the placement flags in @mem, potentially evicting other idle buffer objects. 641 * the placement flags in @mem, potentially evicting other idle buffer objects.
@@ -647,7 +649,8 @@ extern bool ttm_mem_reg_is_pci(struct ttm_bo_device *bdev,
647extern int ttm_bo_mem_space(struct ttm_buffer_object *bo, 649extern int ttm_bo_mem_space(struct ttm_buffer_object *bo,
648 struct ttm_placement *placement, 650 struct ttm_placement *placement,
649 struct ttm_mem_reg *mem, 651 struct ttm_mem_reg *mem,
650 bool interruptible, bool no_wait); 652 bool interruptible,
653 bool no_wait_reserve, bool no_wait_gpu);
651/** 654/**
652 * ttm_bo_wait_for_cpu 655 * ttm_bo_wait_for_cpu
653 * 656 *
@@ -826,7 +829,8 @@ extern void ttm_bo_unblock_reservation(struct ttm_buffer_object *bo);
826 * 829 *
827 * @bo: A pointer to a struct ttm_buffer_object. 830 * @bo: A pointer to a struct ttm_buffer_object.
828 * @evict: 1: This is an eviction. Don't try to pipeline. 831 * @evict: 1: This is an eviction. Don't try to pipeline.
829 * @no_wait: Never sleep, but rather return with -EBUSY. 832 * @no_wait_reserve: Return immediately if other buffers are busy.
833 * @no_wait_gpu: Return immediately if the GPU is busy.
830 * @new_mem: struct ttm_mem_reg indicating where to move. 834 * @new_mem: struct ttm_mem_reg indicating where to move.
831 * 835 *
832 * Optimized move function for a buffer object with both old and 836 * Optimized move function for a buffer object with both old and
@@ -840,15 +844,16 @@ extern void ttm_bo_unblock_reservation(struct ttm_buffer_object *bo);
840 */ 844 */
841 845
842extern int ttm_bo_move_ttm(struct ttm_buffer_object *bo, 846extern int ttm_bo_move_ttm(struct ttm_buffer_object *bo,
843 bool evict, bool no_wait, 847 bool evict, bool no_wait_reserve,
844 struct ttm_mem_reg *new_mem); 848 bool no_wait_gpu, struct ttm_mem_reg *new_mem);
845 849
846/** 850/**
847 * ttm_bo_move_memcpy 851 * ttm_bo_move_memcpy
848 * 852 *
849 * @bo: A pointer to a struct ttm_buffer_object. 853 * @bo: A pointer to a struct ttm_buffer_object.
850 * @evict: 1: This is an eviction. Don't try to pipeline. 854 * @evict: 1: This is an eviction. Don't try to pipeline.
851 * @no_wait: Never sleep, but rather return with -EBUSY. 855 * @no_wait_reserve: Return immediately if other buffers are busy.
856 * @no_wait_gpu: Return immediately if the GPU is busy.
852 * @new_mem: struct ttm_mem_reg indicating where to move. 857 * @new_mem: struct ttm_mem_reg indicating where to move.
853 * 858 *
854 * Fallback move function for a mappable buffer object in mappable memory. 859 * Fallback move function for a mappable buffer object in mappable memory.
@@ -862,8 +867,8 @@ extern int ttm_bo_move_ttm(struct ttm_buffer_object *bo,
862 */ 867 */
863 868
864extern int ttm_bo_move_memcpy(struct ttm_buffer_object *bo, 869extern int ttm_bo_move_memcpy(struct ttm_buffer_object *bo,
865 bool evict, 870 bool evict, bool no_wait_reserve,
866 bool no_wait, struct ttm_mem_reg *new_mem); 871 bool no_wait_gpu, struct ttm_mem_reg *new_mem);
867 872
868/** 873/**
869 * ttm_bo_free_old_node 874 * ttm_bo_free_old_node
@@ -882,7 +887,8 @@ extern void ttm_bo_free_old_node(struct ttm_buffer_object *bo);
882 * @sync_obj_arg: An argument to pass to the sync object idle / wait 887 * @sync_obj_arg: An argument to pass to the sync object idle / wait
883 * functions. 888 * functions.
884 * @evict: This is an evict move. Don't return until the buffer is idle. 889 * @evict: This is an evict move. Don't return until the buffer is idle.
885 * @no_wait: Never sleep, but rather return with -EBUSY. 890 * @no_wait_reserve: Return immediately if other buffers are busy.
891 * @no_wait_gpu: Return immediately if the GPU is busy.
886 * @new_mem: struct ttm_mem_reg indicating where to move. 892 * @new_mem: struct ttm_mem_reg indicating where to move.
887 * 893 *
888 * Accelerated move function to be called when an accelerated move 894 * Accelerated move function to be called when an accelerated move
@@ -896,7 +902,8 @@ extern void ttm_bo_free_old_node(struct ttm_buffer_object *bo);
896extern int ttm_bo_move_accel_cleanup(struct ttm_buffer_object *bo, 902extern int ttm_bo_move_accel_cleanup(struct ttm_buffer_object *bo,
897 void *sync_obj, 903 void *sync_obj,
898 void *sync_obj_arg, 904 void *sync_obj_arg,
899 bool evict, bool no_wait, 905 bool evict, bool no_wait_reserve,
906 bool no_wait_gpu,
900 struct ttm_mem_reg *new_mem); 907 struct ttm_mem_reg *new_mem);
901/** 908/**
902 * ttm_io_prot 909 * ttm_io_prot