Lines Matching refs:bo

164 	struct ttm_buffer_object *bo;  member
208 s64 (*process_bo)(struct ttm_lru_walk *walk, struct ttm_buffer_object *bo);
233 static inline void ttm_bo_get(struct ttm_buffer_object *bo) in ttm_bo_get() argument
235 kref_get(&bo->kref); in ttm_bo_get()
249 ttm_bo_get_unless_zero(struct ttm_buffer_object *bo) in ttm_bo_get_unless_zero() argument
251 if (!kref_get_unless_zero(&bo->kref)) in ttm_bo_get_unless_zero()
253 return bo; in ttm_bo_get_unless_zero()
278 static inline int ttm_bo_reserve(struct ttm_buffer_object *bo, in ttm_bo_reserve() argument
290 success = dma_resv_trylock(bo->base.resv); in ttm_bo_reserve()
295 ret = dma_resv_lock_interruptible(bo->base.resv, ticket); in ttm_bo_reserve()
297 ret = dma_resv_lock(bo->base.resv, ticket); in ttm_bo_reserve()
313 static inline int ttm_bo_reserve_slowpath(struct ttm_buffer_object *bo, in ttm_bo_reserve_slowpath() argument
318 int ret = dma_resv_lock_slow_interruptible(bo->base.resv, in ttm_bo_reserve_slowpath()
324 dma_resv_lock_slow(bo->base.resv, ticket); in ttm_bo_reserve_slowpath()
328 void ttm_bo_move_to_lru_tail(struct ttm_buffer_object *bo);
331 ttm_bo_move_to_lru_tail_unlocked(struct ttm_buffer_object *bo) in ttm_bo_move_to_lru_tail_unlocked() argument
333 spin_lock(&bo->bdev->lru_lock); in ttm_bo_move_to_lru_tail_unlocked()
334 ttm_bo_move_to_lru_tail(bo); in ttm_bo_move_to_lru_tail_unlocked()
335 spin_unlock(&bo->bdev->lru_lock); in ttm_bo_move_to_lru_tail_unlocked()
338 static inline void ttm_bo_assign_mem(struct ttm_buffer_object *bo, in ttm_bo_assign_mem() argument
341 WARN_ON(bo->resource); in ttm_bo_assign_mem()
342 bo->resource = new_mem; in ttm_bo_assign_mem()
352 static inline void ttm_bo_move_null(struct ttm_buffer_object *bo, in ttm_bo_move_null() argument
355 ttm_resource_free(bo, &bo->resource); in ttm_bo_move_null()
356 ttm_bo_assign_mem(bo, new_mem); in ttm_bo_move_null()
366 static inline void ttm_bo_unreserve(struct ttm_buffer_object *bo) in ttm_bo_unreserve() argument
368 ttm_bo_move_to_lru_tail_unlocked(bo); in ttm_bo_unreserve()
369 dma_resv_unlock(bo->base.resv); in ttm_bo_unreserve()
390 int ttm_bo_wait_ctx(struct ttm_buffer_object *bo,
392 int ttm_bo_validate(struct ttm_buffer_object *bo,
395 void ttm_bo_put(struct ttm_buffer_object *bo);
396 void ttm_bo_set_bulk_move(struct ttm_buffer_object *bo,
398 bool ttm_bo_eviction_valuable(struct ttm_buffer_object *bo,
400 int ttm_bo_init_reserved(struct ttm_device *bdev, struct ttm_buffer_object *bo,
405 int ttm_bo_init_validate(struct ttm_device *bdev, struct ttm_buffer_object *bo,
410 int ttm_bo_kmap(struct ttm_buffer_object *bo, unsigned long start_page,
413 int ttm_bo_vmap(struct ttm_buffer_object *bo, struct iosys_map *map);
414 void ttm_bo_vunmap(struct ttm_buffer_object *bo, struct iosys_map *map);
415 int ttm_bo_mmap_obj(struct vm_area_struct *vma, struct ttm_buffer_object *bo);
419 void ttm_bo_pin(struct ttm_buffer_object *bo);
420 void ttm_bo_unpin(struct ttm_buffer_object *bo);
424 vm_fault_t ttm_bo_vm_reserve(struct ttm_buffer_object *bo,
436 int ttm_bo_mem_space(struct ttm_buffer_object *bo,
441 void ttm_bo_unmap_virtual(struct ttm_buffer_object *bo);
452 int ttm_bo_move_memcpy(struct ttm_buffer_object *bo,
455 int ttm_bo_move_accel_cleanup(struct ttm_buffer_object *bo,
459 void ttm_bo_move_sync_cleanup(struct ttm_buffer_object *bo,
461 int ttm_bo_pipeline_gutting(struct ttm_buffer_object *bo);
462 pgprot_t ttm_io_prot(struct ttm_buffer_object *bo, struct ttm_resource *res,
464 void ttm_bo_tt_destroy(struct ttm_buffer_object *bo);