| /linux/include/linux/ |
| H A D | dma-fence.h | 33 * @refcount: refcount for this fence 34 * @ops: dma_fence_ops associated with this fence 35 * @rcu: used for releasing fence with kfree_rcu 39 * @context: execution context this fence belongs to, returned by 41 * @seqno: the sequence number of this fence inside the execution context, 42 * can be compared to decide which fence would be signaled later. 44 * @timestamp: Timestamp when the fence was signaled. 46 * dma_fence_signal, indicates that the fence has completed with an error. 52 * DMA_FENCE_FLAG_INITIALIZED_BIT - fence was initialized 54 * DMA_FENCE_FLAG_SIGNALED_BIT - fence i 299 dma_fence_was_initialized(struct dma_fence * fence) dma_fence_was_initialized() argument 308 dma_fence_put(struct dma_fence * fence) dma_fence_put() argument 320 dma_fence_get(struct dma_fence * fence) dma_fence_get() argument 334 dma_fence_get_rcu(struct dma_fence * fence) dma_fence_get_rcu() argument 362 struct dma_fence *fence; dma_fence_get_rcu_safe() local 398 dma_fence_spinlock(struct dma_fence * fence) dma_fence_spinlock() argument 411 dma_fence_lock_irqsave(fence,flags) global() argument 421 dma_fence_unlock_irqrestore(fence,flags) global() argument 428 dma_fence_assert_held(fence) global() argument 497 dma_fence_test_signaled_flag(struct dma_fence * fence) dma_fence_test_signaled_flag() argument 517 dma_fence_is_signaled_locked(struct dma_fence * fence) dma_fence_is_signaled_locked() argument 553 dma_fence_is_signaled(struct dma_fence * fence) dma_fence_is_signaled() argument 581 __dma_fence_is_later(struct dma_fence * fence,u64 f1,u64 f2) __dma_fence_is_later() argument 665 dma_fence_get_status_locked(struct dma_fence * fence) dma_fence_get_status_locked() argument 692 dma_fence_set_error(struct dma_fence * fence,int error) dma_fence_set_error() argument 709 dma_fence_timestamp(struct dma_fence * fence) dma_fence_timestamp() argument 742 dma_fence_wait(struct dma_fence * fence,bool intr) dma_fence_wait() argument 770 dma_fence_is_array(struct dma_fence * fence) dma_fence_is_array() argument 781 dma_fence_is_chain(struct dma_fence * fence) dma_fence_is_chain() argument 794 dma_fence_is_container(struct dma_fence * fence) dma_fence_is_container() argument [all...] |
| H A D | dma-fence-chain.h | 28 struct dma_fence *fence; member 59 to_dma_fence_chain(struct dma_fence *fence) in to_dma_fence_chain() argument 61 if (!fence || !dma_fence_is_chain(fence)) in to_dma_fence_chain() 64 return container_of(fence, struct dma_fence_chain, base); in to_dma_fence_chain() 75 dma_fence_chain_contained(struct dma_fence *fence) in dma_fence_chain_contained() argument 77 struct dma_fence_chain *chain = to_dma_fence_chain(fence); in dma_fence_chain_contained() 79 return chain ? chain->fence : fence; in dma_fence_chain_contained() 122 struct dma_fence *dma_fence_chain_walk(struct dma_fence *fence); 126 struct dma_fence *fence,
|
| /linux/drivers/dma-buf/ |
| H A D | dma-fence.c | 113 static const char *dma_fence_stub_get_name(struct dma_fence *fence) in dma_fence_stub_get_name() argument 153 struct dma_fence *fence; in dma_fence_allocate_private_stub() local 155 fence = kzalloc_obj(*fence); in dma_fence_allocate_private_stub() 156 if (fence == NULL) in dma_fence_allocate_private_stub() 159 dma_fence_init(fence, &dma_fence_stub_ops, NULL, 0, 0); in dma_fence_allocate_private_stub() 161 &fence->flags); in dma_fence_allocate_private_stub() 163 dma_fence_signal_timestamp(fence, timestamp); in dma_fence_allocate_private_stub() 165 return fence; in dma_fence_allocate_private_stub() 353 void dma_fence_signal_timestamp_locked(struct dma_fence *fence, in dma_fence_signal_timestamp_locked() argument 360 dma_fence_assert_held(fence); in dma_fence_signal_timestamp_locked() [all …]
|
| H A D | sync_file.c | 65 struct sync_file *sync_file_create(struct dma_fence *fence) in sync_file_create() argument 73 sync_file->fence = dma_fence_get(fence); in sync_file_create() 106 struct dma_fence *fence; in sync_file_get_fence() local 112 fence = dma_fence_get(sync_file->fence); in sync_file_get_fence() 115 return fence; in sync_file_get_fence() 137 struct dma_fence *fence = sync_file->fence; in sync_file_get_name() local 142 driver = dma_fence_driver_name(fence); in sync_file_get_name() 143 timeline = dma_fence_timeline_name(fence); in sync_file_get_name() 147 fence->context, in sync_file_get_name() 148 fence->seqno); in sync_file_get_name() [all …]
|
| /linux/drivers/gpu/drm/i915/ |
| H A D | i915_sw_fence.c | 49 static inline void debug_fence_init(struct i915_sw_fence *fence) in debug_fence_init() argument 51 debug_object_init(fence, &i915_sw_fence_debug_descr); in debug_fence_init() 54 static inline __maybe_unused void debug_fence_init_onstack(struct i915_sw_fence *fence) in debug_fence_init_onstack() argument 56 debug_object_init_on_stack(fence, &i915_sw_fence_debug_descr); in debug_fence_init_onstack() 59 static inline void debug_fence_activate(struct i915_sw_fence *fence) in debug_fence_activate() argument 61 debug_object_activate(fence, &i915_sw_fence_debug_descr); in debug_fence_activate() 64 static inline void debug_fence_set_state(struct i915_sw_fence *fence, in debug_fence_set_state() argument 67 debug_object_active_state(fence, &i915_sw_fence_debug_descr, old, new); in debug_fence_set_state() 70 static inline void debug_fence_deactivate(struct i915_sw_fence *fence) in debug_fence_deactivate() argument 72 debug_object_deactivate(fence, &i915_sw_fence_debug_descr); in debug_fence_deactivate() [all …]
|
| H A D | i915_sw_fence.h | 42 void __i915_sw_fence_init(struct i915_sw_fence *fence, 47 #define i915_sw_fence_init(fence, fn) \ argument 52 __i915_sw_fence_init((fence), (fn), #fence, &__key); \ 55 #define i915_sw_fence_init(fence, fn) \ argument 58 __i915_sw_fence_init((fence), (fn), NULL, NULL); \ 62 void i915_sw_fence_reinit(struct i915_sw_fence *fence); 65 void i915_sw_fence_fini(struct i915_sw_fence *fence); 67 static inline void i915_sw_fence_fini(struct i915_sw_fence *fence) {} in i915_sw_fence_fini() argument 70 void i915_sw_fence_commit(struct i915_sw_fence *fence); 72 int i915_sw_fence_await_sw_fence(struct i915_sw_fence *fence, [all …]
|
| H A D | i915_active.h | 48 void i915_active_noop(struct dma_fence *fence, struct dma_fence_cb *cb); 64 void *fence, in __i915_active_fence_init() argument 67 RCU_INIT_POINTER(active->fence, fence); in __i915_active_fence_init() 76 struct dma_fence *fence); 103 struct dma_fence *fence; in i915_active_fence_get() local 106 fence = dma_fence_get_rcu_safe(&active->fence); in i915_active_fence_get() 109 return fence; in i915_active_fence_get() 123 return rcu_access_pointer(active->fence); in i915_active_fence_isset() 178 int i915_sw_fence_await_active(struct i915_sw_fence *fence, 222 struct dma_fence *fence; in __i915_request_await_exclusive() local [all …]
|
| H A D | i915_active.c | 45 return IS_ERR(rcu_access_pointer(active->fence)); in is_barrier() 138 GEM_BUG_ON(rcu_access_pointer(ref->excl.fence)); in __active_retire() 206 return (struct dma_fence ** __force)&active->fence; in __active_fence_slot() 210 active_fence_cb(struct dma_fence *fence, struct dma_fence_cb *cb) in active_fence_cb() argument 215 return try_cmpxchg(__active_fence_slot(active), &fence, NULL); in active_fence_cb() 219 node_retire(struct dma_fence *fence, struct dma_fence_cb *cb) in node_retire() argument 221 if (active_fence_cb(fence, cb)) in node_retire() 226 excl_retire(struct dma_fence *fence, struct dma_fence_cb *cb) in excl_retire() argument 228 if (active_fence_cb(fence, cb)) in excl_retire() 434 struct dma_fence *fence = &rq->fence; in i915_active_add_request() local [all …]
|
| H A D | i915_deps.c | 75 static int i915_deps_grow(struct i915_deps *deps, struct dma_fence *fence, in i915_deps_grow() argument 96 deps->fences[deps->num_deps++] = dma_fence_get(fence); in i915_deps_grow() 100 if (ctx->no_wait_gpu && !dma_fence_is_signaled(fence)) { in i915_deps_grow() 105 ret = dma_fence_wait(fence, ctx->interruptible); in i915_deps_grow() 109 ret = fence->error; in i915_deps_grow() 177 struct dma_fence *fence, in i915_deps_add_dependency() argument 183 if (!fence) in i915_deps_add_dependency() 186 if (dma_fence_is_signaled(fence)) { in i915_deps_add_dependency() 187 ret = fence->error; in i915_deps_add_dependency() 196 if (!entry->context || entry->context != fence->context) in i915_deps_add_dependency() [all …]
|
| /linux/drivers/gpu/drm/vmwgfx/ |
| H A D | vmwgfx_fence.c | 23 struct vmw_fence_obj fence; member 48 fman_from_fence(struct vmw_fence_obj *fence) in fman_from_fence() argument 50 return container_of(fence->base.extern_lock, struct vmw_fence_manager, in fman_from_fence() 56 struct vmw_fence_obj *fence = in vmw_fence_obj_destroy() local 58 struct vmw_fence_manager *fman = fman_from_fence(fence); in vmw_fence_obj_destroy() 60 if (!list_empty(&fence->head)) { in vmw_fence_obj_destroy() 73 list_del_init(&fence->head); in vmw_fence_obj_destroy() 74 if (fence->waiter_added) in vmw_fence_obj_destroy() 78 fence->destroy(fence); in vmw_fence_obj_destroy() 101 struct vmw_fence_obj *fence = in vmw_fence_enable_signaling() local [all …]
|
| /linux/drivers/gpu/drm/xe/ |
| H A D | xe_tlb_inval.c | 40 static void xe_tlb_inval_fence_fini(struct xe_tlb_inval_fence *fence) 42 if (WARN_ON_ONCE(!fence->tlb_inval)) in xe_tlb_inval_fence_signal() argument 45 xe_pm_runtime_put(fence->tlb_inval->xe); in xe_tlb_inval_fence_signal() 46 fence->tlb_inval = NULL; /* fini() should be called once */ in xe_tlb_inval_fence_signal() 50 xe_tlb_inval_fence_signal(struct xe_tlb_inval_fence *fence) in xe_tlb_inval_fence_signal() 52 struct xe_tlb_inval *tlb_inval = fence->tlb_inval; in xe_tlb_inval_fence_signal() 53 bool stack = test_bit(FENCE_STACK_BIT, &fence->base.flags); in xe_tlb_inval_fence_signal() 55 lockdep_assert_held(&fence->tlb_inval->pending_lock); in xe_tlb_inval_fence_signal() 57 list_del(&fence->link); in xe_tlb_inval_fence_signal() 60 trace_xe_tlb_inval_fence_signal(fence argument 32 xe_tlb_inval_fence_fini(struct xe_tlb_inval_fence * fence) xe_tlb_inval_fence_fini() argument 74 struct xe_tlb_inval_fence *fence, *next; xe_tlb_inval_fence_timeout() local 179 struct xe_tlb_inval_fence *fence, *next; xe_tlb_inval_reset() local 247 xe_tlb_inval_fence_prep(struct xe_tlb_inval_fence * fence) xe_tlb_inval_fence_prep() argument 299 xe_tlb_inval_all(struct xe_tlb_inval * tlb_inval,struct xe_tlb_inval_fence * fence) xe_tlb_inval_all() argument 315 struct xe_tlb_inval_fence fence, *fence_ptr = &fence; xe_tlb_inval_ggtt() local 342 xe_tlb_inval_range(struct xe_tlb_inval * tlb_inval,struct xe_tlb_inval_fence * fence,u64 start,u64 end,u32 asid,struct drm_suballoc * prl_sa) xe_tlb_inval_range() argument 358 struct xe_tlb_inval_fence fence; xe_tlb_inval_vm() local 376 struct xe_tlb_inval_fence *fence, *next; xe_tlb_inval_done_handler() local 456 xe_tlb_inval_fence_init(struct xe_tlb_inval * tlb_inval,struct xe_tlb_inval_fence * fence,bool stack) xe_tlb_inval_fence_init() argument 500 struct xe_tlb_inval_fence *fence = &batch->fence[0]; xe_tlb_inval_batch_wait() local 529 struct xe_tlb_inval_fence *fence = &batch->fence[0]; xe_tlb_inval_range_tilemask_submit() local [all...] |
| /linux/drivers/gpu/drm/vgem/ |
| H A D | vgem_fence.c | 38 static const char *vgem_fence_get_driver_name(struct dma_fence *fence) in vgem_fence_get_driver_name() argument 43 static const char *vgem_fence_get_timeline_name(struct dma_fence *fence) in vgem_fence_get_timeline_name() argument 50 struct vgem_fence *fence = container_of(base, typeof(*fence), base); in vgem_fence_release() local 52 timer_delete_sync(&fence->timer); in vgem_fence_release() 53 dma_fence_free(&fence->base); in vgem_fence_release() 64 struct vgem_fence *fence = timer_container_of(fence, t, timer); in vgem_fence_timeout() local 66 dma_fence_signal(&fence->base); in vgem_fence_timeout() 72 struct vgem_fence *fence; in vgem_fence_create() local 74 fence = kzalloc_obj(*fence); in vgem_fence_create() 75 if (!fence) in vgem_fence_create() [all …]
|
| /linux/drivers/gpu/drm/i915/selftests/ |
| H A D | lib_sw_fence.c | 30 nop_fence_notify(struct i915_sw_fence *fence, enum i915_sw_fence_notify state) in nop_fence_notify() argument 35 void __onstack_fence_init(struct i915_sw_fence *fence, in __onstack_fence_init() argument 39 debug_fence_init_onstack(fence); in __onstack_fence_init() 41 __init_waitqueue_head(&fence->wait, name, key); in __onstack_fence_init() 42 atomic_set(&fence->pending, 1); in __onstack_fence_init() 43 fence->error = 0; in __onstack_fence_init() 44 fence->fn = nop_fence_notify; in __onstack_fence_init() 47 void onstack_fence_fini(struct i915_sw_fence *fence) in onstack_fence_fini() argument 49 if (!fence->fn) in onstack_fence_fini() 52 i915_sw_fence_commit(fence); in onstack_fence_fini() [all …]
|
| H A D | lib_sw_fence.h | 16 #define onstack_fence_init(fence) \ argument 20 __onstack_fence_init((fence), #fence, &__key); \ 23 #define onstack_fence_init(fence) \ argument 24 __onstack_fence_init((fence), NULL, NULL) 27 void __onstack_fence_init(struct i915_sw_fence *fence, 30 void onstack_fence_fini(struct i915_sw_fence *fence); 33 struct i915_sw_fence fence; member 41 void heap_fence_put(struct i915_sw_fence *fence);
|
| /linux/drivers/gpu/drm/radeon/ |
| H A D | radeon_fence.c | 50 * for GPU/CPU synchronization. When the fence is written, 51 * it is expected that all buffers associated with that fence 59 * radeon_fence_write - write a fence value 63 * @ring: ring index the fence is associated with 65 * Writes a fence value to memory or a scratch register (all asics). 80 * radeon_fence_read - read a fence value 83 * @ring: ring index the fence is associated with 85 * Reads a fence value from memory or a scratch register (all asics). 86 * Returns the value of the fence read from memory or register. 124 * radeon_fence_emit - emit a fence o 134 radeon_fence_emit(struct radeon_device * rdev,struct radeon_fence ** fence,int ring) radeon_fence_emit() argument 168 struct radeon_fence *fence; radeon_fence_check_signaled() local 355 struct radeon_fence *fence = to_radeon_fence(f); radeon_fence_is_signaled() local 383 struct radeon_fence *fence = to_radeon_fence(f); radeon_fence_enable_signaling() local 426 radeon_fence_signaled(struct radeon_fence * fence) radeon_fence_signaled() argument 533 radeon_fence_wait_timeout(struct radeon_fence * fence,bool intr,long timeout) radeon_fence_wait_timeout() argument 567 radeon_fence_wait(struct radeon_fence * fence,bool intr) radeon_fence_wait() argument 645 radeon_fence_ref(struct radeon_fence * fence) radeon_fence_ref() argument 658 radeon_fence_unref(struct radeon_fence ** fence) radeon_fence_unref() argument 705 radeon_fence_need_sync(struct radeon_fence * fence,int dst_ring) radeon_fence_need_sync() argument 732 radeon_fence_note_sync(struct radeon_fence * fence,int dst_ring) radeon_fence_note_sync() argument 967 radeon_fence_get_driver_name(struct dma_fence * fence) radeon_fence_get_driver_name() argument 974 struct radeon_fence *fence = to_radeon_fence(f); radeon_fence_get_timeline_name() local 991 radeon_test_signaled(struct radeon_fence * fence) radeon_test_signaled() argument 1002 radeon_fence_wait_cb(struct dma_fence * fence,struct dma_fence_cb * cb) radeon_fence_wait_cb() argument 1013 struct radeon_fence *fence = to_radeon_fence(f); radeon_fence_default_wait() local [all...] |
| H A D | radeon_sync.c | 63 struct radeon_fence *fence) in radeon_sync_fence() argument 67 if (!fence) in radeon_sync_fence() 70 other = sync->sync_to[fence->ring]; in radeon_sync_fence() 71 sync->sync_to[fence->ring] = radeon_fence_later(fence, other); in radeon_sync_fence() 73 if (fence->is_vm_update) { in radeon_sync_fence() 75 sync->last_vm_update = radeon_fence_later(fence, other); in radeon_sync_fence() 95 struct radeon_fence *fence; in radeon_sync_resv() local 100 fence = to_radeon_fence(f); in radeon_sync_resv() 101 if (fence && fence->rdev == rdev) in radeon_sync_resv() 102 radeon_sync_fence(sync, fence); in radeon_sync_resv() [all …]
|
| /linux/drivers/gpu/drm/ |
| H A D | drm_syncobj.c | 3 * Parts ported from amdgpu (fence wait code). 41 * - Import and export a syncobj's underlying fence to/from a sync file 42 * - Reset a syncobj (set its fence to NULL) 43 * - Signal a syncobj (set a trivially signaled fence) 44 * - Wait for a syncobj's fence to appear and be signaled 57 * to an already signaled fence depending on whether the 63 * the syncobj, the syncobj's fence is replaced with a fence which will be 67 * struct &dma_fence_chain pointing to the DRM driver's fence and also 68 * pointing to the previous fence tha 218 struct dma_fence *fence; global() member 228 struct dma_fence *fence; global() member 269 struct dma_fence *fence; drm_syncobj_fence_add_wait() local 335 drm_syncobj_add_point(struct drm_syncobj * syncobj,struct dma_fence_chain * chain,struct dma_fence * fence,uint64_t point) drm_syncobj_add_point() argument 373 drm_syncobj_replace_fence(struct drm_syncobj * syncobj,struct dma_fence * fence) drm_syncobj_replace_fence() argument 409 struct dma_fence *fence = dma_fence_allocate_private_stub(ktime_get()); drm_syncobj_assign_null_handle() local 438 drm_syncobj_find_fence(struct drm_file * file_private,u32 handle,u64 point,u64 flags,struct dma_fence ** fence) drm_syncobj_find_fence() argument 557 drm_syncobj_create(struct drm_syncobj ** out_syncobj,uint32_t flags,struct dma_fence * fence) drm_syncobj_create() argument 731 struct dma_fence *fence = sync_file_get_fence(fd); drm_syncobj_import_sync_file_fence() local 763 struct dma_fence *fence; drm_syncobj_export_sync_file() local 925 struct dma_fence *fence, *tmp; drm_syncobj_transfer_to_timeline() local 966 struct dma_fence *fence; drm_syncobj_transfer_to_binary() local 1004 syncobj_wait_fence_func(struct dma_fence * fence,struct dma_fence_cb * cb) syncobj_wait_fence_func() argument 1016 struct dma_fence *fence; syncobj_wait_syncobj_func() local 1044 struct dma_fence *fence; drm_syncobj_array_wait_timeout() local 1079 struct dma_fence *fence; drm_syncobj_array_wait_timeout() local 1409 syncobj_eventfd_entry_fence_func(struct dma_fence * fence,struct dma_fence_cb * cb) syncobj_eventfd_entry_fence_func() argument 1424 struct dma_fence *fence; syncobj_eventfd_entry_func() local 1638 struct dma_fence *fence = dma_fence_get_stub(); drm_syncobj_timeline_signal_ioctl() local 1681 struct dma_fence *fence; drm_syncobj_query_ioctl() local [all...] |
| /linux/drivers/gpu/drm/amd/amdgpu/ |
| H A D | amdgpu_userq_fence.c | 27 #include <linux/dma-fence-unwrap.h> 149 struct dma_fence *fence; in amdgpu_userq_fence_driver_process() local 169 fence = &userq_fence->base; in amdgpu_userq_fence_driver_process() 171 dma_fence_signal(fence); in amdgpu_userq_fence_driver_process() 176 dma_fence_put(fence); in amdgpu_userq_fence_driver_process() 189 struct amdgpu_userq_fence *fence, *tmp; in amdgpu_userq_fence_driver_destroy() local 195 list_for_each_entry_safe(fence, tmp, &fence_drv->fences, link) { in amdgpu_userq_fence_driver_destroy() 196 f = &fence->base; in amdgpu_userq_fence_driver_destroy() 203 list_del(&fence->link); in amdgpu_userq_fence_driver_destroy() 269 struct amdgpu_userq_fence *fence, in amdgpu_userq_fence_init() argument 308 struct amdgpu_userq_fence *fence = to_amdgpu_userq_fence(f); amdgpu_userq_fence_get_timeline_name() local 315 struct amdgpu_userq_fence *fence = to_amdgpu_userq_fence(f); amdgpu_userq_fence_signaled() local 330 struct dma_fence *fence = container_of(rcu, struct dma_fence, rcu); amdgpu_userq_fence_free() local 417 amdgpu_userq_fence_driver_set_error(struct amdgpu_userq_fence * fence,int error) amdgpu_userq_fence_driver_set_error() argument 444 struct amdgpu_userq_fence *fence = to_amdgpu_userq_fence(f); amdgpu_userq_fence_driver_force_completion() local 468 struct amdgpu_userq_fence *fence; amdgpu_userq_signal_ioctl() local 609 struct dma_fence *fence, *f; amdgpu_userq_wait_count_fences() local 670 struct dma_fence *fence; amdgpu_userq_wait_count_fences() local 680 struct dma_fence *fence; amdgpu_userq_wait_count_fences() local 699 amdgpu_userq_wait_add_fence(struct drm_amdgpu_userq_wait * wait_info,struct dma_fence ** fences,unsigned int * num_fences,struct dma_fence * fence) amdgpu_userq_wait_add_fence() argument 722 struct dma_fence **fences, *fence, *f; amdgpu_userq_wait_return_fence_info() local 766 struct dma_fence *fence; amdgpu_userq_wait_return_fence_info() local 805 struct dma_fence *fence; amdgpu_userq_wait_return_fence_info() local 819 struct dma_fence *fence; amdgpu_userq_wait_return_fence_info() local [all...] |
| H A D | amdgpu_fence.c | 56 * amdgpu_fence_write - write a fence value 58 * @ring: ring the fence is associated with 61 * Writes a fence value to memory (all asics). 72 * amdgpu_fence_read - read a fence value 74 * @ring: ring the fence is associated with 76 * Reads a fence value from memory (all asics). 77 * Returns the value of the fence read from memory. 93 * amdgpu_fence_emit - emit a fence on the requested ring 95 * @ring: ring the fence is associated with 96 * @af: amdgpu fence inpu 105 struct dma_fence *fence; amdgpu_fence_emit() local 230 struct dma_fence *fence, **ptr; amdgpu_fence_process() local 280 struct dma_fence *fence, **ptr; amdgpu_fence_wait_empty() local 353 struct dma_fence *fence; amdgpu_fence_last_unsignaled_time_us() local 384 struct dma_fence *fence; amdgpu_fence_update_start_timestamp() local 651 struct dma_fence *fence; amdgpu_fence_driver_set_error() local 676 struct dma_fence *fence; amdgpu_fence_driver_force_completion() local 720 struct amdgpu_fence *fence; amdgpu_ring_set_fence_errors_and_reemit() local 807 struct amdgpu_fence *fence; amdgpu_ring_backup_unprocessed_commands() local 845 struct amdgpu_fence *fence; amdgpu_ring_find_guilty_fence() local 874 amdgpu_fence_get_driver_name(struct dma_fence * fence) amdgpu_fence_get_driver_name() argument [all...] |
| /linux/tools/testing/selftests/sync/ |
| H A D | sync_stress_consumer.c | 40 static int busy_wait_on_fence(int fence) in busy_wait_on_fence() argument 45 error = sync_fence_count_with_status(fence, FENCE_STATUS_ERROR); in busy_wait_on_fence() 47 active = sync_fence_count_with_status(fence, in busy_wait_on_fence() 66 int fence, valid, i; in mpsc_producer_thread() local 72 fence = sw_sync_fence_create(consumer_timeline, "fence", i); in mpsc_producer_thread() 73 valid = sw_sync_fence_is_valid(fence); in mpsc_producer_thread() 82 ASSERT(sync_wait(fence, -1) > 0, in mpsc_producer_thread() 85 ASSERT(busy_wait_on_fence(fence) == 0, in mpsc_producer_thread() 100 sw_sync_fence_destroy(fence); in mpsc_producer_thread() 108 int fence, merged, tmp, valid, it, i; in mpcs_consumer_thread() local [all …]
|
| /linux/drivers/gpu/drm/virtio/ |
| H A D | virtgpu_fence.c | 64 struct virtio_gpu_fence *fence = kzalloc_obj(struct virtio_gpu_fence); in virtio_gpu_fence_alloc() local 66 if (!fence) in virtio_gpu_fence_alloc() 67 return fence; in virtio_gpu_fence_alloc() 69 fence->drv = drv; in virtio_gpu_fence_alloc() 70 fence->ring_idx = ring_idx; in virtio_gpu_fence_alloc() 71 fence->emit_fence_info = !(base_fence_ctx == drv->context); in virtio_gpu_fence_alloc() 78 dma_fence_init(&fence->f, &virtio_gpu_fence_ops, &drv->lock, in virtio_gpu_fence_alloc() 81 return fence; in virtio_gpu_fence_alloc() 86 struct virtio_gpu_fence *fence) in virtio_gpu_fence_emit() argument 92 fence->fence_id = fence->f.seqno = ++drv->current_fence_id; in virtio_gpu_fence_emit() [all …]
|
| /linux/drivers/gpu/drm/msm/ |
| H A D | msm_fence.c | 82 bool msm_fence_completed(struct msm_fence_context *fctx, uint32_t fence) in msm_fence_completed() argument 88 return (int32_t)(fctx->completed_fence - fence) >= 0 || in msm_fence_completed() 89 (int32_t)(*fctx->fenceptr - fence) >= 0; in msm_fence_completed() 93 void msm_update_fence(struct msm_fence_context *fctx, uint32_t fence) in msm_update_fence() argument 98 if (fence_after(fence, fctx->completed_fence)) in msm_update_fence() 99 fctx->completed_fence = fence; in msm_update_fence() 110 static inline struct msm_fence *to_msm_fence(struct dma_fence *fence) in to_msm_fence() argument 112 return container_of(fence, struct msm_fence, base); in to_msm_fence() 115 static const char *msm_fence_get_driver_name(struct dma_fence *fence) in msm_fence_get_driver_name() argument 120 static const char *msm_fence_get_timeline_name(struct dma_fence *fence) in msm_fence_get_timeline_name() argument [all …]
|
| /linux/drivers/gpu/drm/xe/tests/ |
| H A D | xe_migrate.c | 16 static bool sanity_fence_failed(struct xe_device *xe, struct dma_fence *fence, in sanity_fence_failed() argument 21 if (IS_ERR(fence)) { in sanity_fence_failed() 23 PTR_ERR(fence)); in sanity_fence_failed() 26 if (!fence) in sanity_fence_failed() 29 ret = dma_fence_wait_timeout(fence, false, 5 * HZ); in sanity_fence_failed() 46 struct dma_fence *fence; in run_sanity_job() local 55 fence = dma_fence_get(&job->drm.s_fence->finished); in run_sanity_job() 58 if (sanity_fence_failed(xe, fence, str, test)) in run_sanity_job() 61 dma_fence_put(fence); in run_sanity_job() 79 struct dma_fence *fence; in test_copy() local [all …]
|
| /linux/tools/memory-model/ |
| H A D | linux-kernel.cat | 53 * smp_mb__after_unlock_lock() fence only affects a single lock handover. 58 * to the CPU that executes the fence. Therefore, all those stores are 59 * also affected by the fence. 65 let strong-fence = mb | gp 67 let nonrw-fence = strong-fence | po-rel | acq-po 68 let fence = nonrw-fence | wmb | rmb 95 let ppo = to-r | to-w | (fence & int) | (po-unlock-lock-po & int) 100 let cumul-fence [all...] |
| /linux/drivers/gpu/drm/nouveau/ |
| H A D | nv84_fence.c | 86 nv84_fence_emit(struct nouveau_fence *fence) in nv84_fence_emit() argument 88 struct nouveau_channel *chan = fence->channel; in nv84_fence_emit() 89 struct nv84_fence_chan *fctx = chan->fence; in nv84_fence_emit() 92 return fctx->base.emit32(chan, addr, fence->base.seqno); in nv84_fence_emit() 96 nv84_fence_sync(struct nouveau_fence *fence, in nv84_fence_sync() argument 99 struct nv84_fence_chan *fctx = chan->fence; in nv84_fence_sync() 102 return fctx->base.sync32(chan, addr, fence->base.seqno); in nv84_fence_sync() 108 struct nv84_fence_priv *priv = chan->cli->drm->fence; in nv84_fence_read() 115 struct nv84_fence_priv *priv = chan->cli->drm->fence; in nv84_fence_context_del() 116 struct nv84_fence_chan *fctx = chan->fence; in nv84_fence_context_del() [all …]
|