Lines Matching defs:fence
7 #include <linux/dma-fence.h>
34 /* If deadline fence has already passed, nothing to do: */
61 * Start out close to the 32b fence rollover point, so we can
62 * catch bugs with fence comparisons.
83 bool msm_fence_completed(struct msm_fence_context *fctx, uint32_t fence)
89 return (int32_t)(fctx->completed_fence - fence) >= 0 ||
90 (int32_t)(*fctx->fenceptr - fence) >= 0;
94 void msm_update_fence(struct msm_fence_context *fctx, uint32_t fence)
99 if (fence_after(fence, fctx->completed_fence))
100 fctx->completed_fence = fence;
111 static inline struct msm_fence *to_msm_fence(struct dma_fence *fence)
113 return container_of(fence, struct msm_fence, base);
116 static const char *msm_fence_get_driver_name(struct dma_fence *fence)
121 static const char *msm_fence_get_timeline_name(struct dma_fence *fence)
123 struct msm_fence *f = to_msm_fence(fence);
127 static bool msm_fence_signaled(struct dma_fence *fence)
129 struct msm_fence *f = to_msm_fence(fence);
133 static void msm_fence_set_deadline(struct dma_fence *fence, ktime_t deadline)
135 struct msm_fence *f = to_msm_fence(fence);
147 max(fctx->next_deadline_fence, (uint32_t)fence->seqno);
188 msm_fence_init(struct dma_fence *fence, struct msm_fence_context *fctx)
190 struct msm_fence *f = to_msm_fence(fence);
195 * Until this point, the fence was just some pre-allocated memory,
198 WARN_ON(kref_read(&fence->refcount));