Lines Matching full:dma

1 Buffer Sharing and Synchronization (dma-buf)
4 The dma-buf subsystem provides the framework for sharing buffers for
5 hardware (DMA) access across multiple device drivers and subsystems, and
14 interact with the three main primitives offered by dma-buf:
16 - dma-buf, representing a sg_table and exposed to userspace as a file
19 - dma-fence, providing a mechanism to signal when an asynchronous
21 - dma-resv, which manages a set of dma-fences for a particular dma-buf
29 For more details on how to design your subsystem's API for dma-buf use, please
30 see Documentation/userspace-api/dma-buf-alloc-exchange.rst.
33 Shared DMA Buffers
36 This document serves as a guide to device-driver writers on what is the dma-buf
39 Any device driver which wishes to be a part of DMA buffer sharing, can do so as
65 Any exporters or users of the dma-buf buffer sharing framework must have a
71 Mostly a DMA buffer file descriptor is simply an opaque object for userspace,
75 - Since kernel 3.12 the dma-buf FD supports the llseek system call, but only
80 If llseek on dma-buf FDs isn't supported the kernel will report -ESPIPE for all
81 cases. Userspace can use this to detect support for discovering the dma-buf
97 flag be set when the dma-buf fd is created. So any API provided by
101 - Memory mapping the contents of the DMA buffer is also supported. See the
102 discussion below on `CPU Access to DMA Buffer Objects`_ for the full details.
104 - The DMA buffer FD is also pollable, see `Implicit Fence Poll Support`_ below for
107 - The DMA buffer FD also supports a few dma-buf-specific ioctls, see
108 `DMA Buffer ioctls`_ below for details.
110 Basic Operation and Device DMA Access
113 .. kernel-doc:: drivers/dma-buf/dma-buf.c
114 :doc: dma buf device access
116 CPU Access to DMA Buffer Objects
119 .. kernel-doc:: drivers/dma-buf/dma-buf.c
125 .. kernel-doc:: drivers/dma-buf/dma-buf.c
128 DMA-BUF statistics
130 .. kernel-doc:: drivers/dma-buf/dma-buf-sysfs-stats.c
133 DMA Buffer ioctls
136 .. kernel-doc:: include/uapi/linux/dma-buf.h
138 DMA-BUF locking convention
141 .. kernel-doc:: drivers/dma-buf/dma-buf.c
147 .. kernel-doc:: drivers/dma-buf/dma-buf.c
150 .. kernel-doc:: include/linux/dma-buf.h
156 .. kernel-doc:: drivers/dma-buf/dma-resv.c
159 .. kernel-doc:: drivers/dma-buf/dma-resv.c
162 .. kernel-doc:: include/linux/dma-resv.h
165 DMA Fences
168 .. kernel-doc:: drivers/dma-buf/dma-fence.c
169 :doc: DMA fences overview
171 DMA Fence Cross-Driver Contract
174 .. kernel-doc:: drivers/dma-buf/dma-fence.c
177 DMA Fence Signalling Annotations
180 .. kernel-doc:: drivers/dma-buf/dma-fence.c
183 DMA Fence Deadline Hints
186 .. kernel-doc:: drivers/dma-buf/dma-fence.c
189 DMA Fences Functions Reference
192 .. kernel-doc:: drivers/dma-buf/dma-fence.c
195 .. kernel-doc:: include/linux/dma-fence.h
198 DMA Fence Array
201 .. kernel-doc:: drivers/dma-buf/dma-fence-array.c
204 .. kernel-doc:: include/linux/dma-fence-array.h
207 DMA Fence Chain
210 .. kernel-doc:: drivers/dma-buf/dma-fence-chain.c
213 .. kernel-doc:: include/linux/dma-fence-chain.h
216 DMA Fence unwrap
219 .. kernel-doc:: include/linux/dma-fence-unwrap.h
222 DMA Fence Sync File
225 .. kernel-doc:: drivers/dma-buf/sync_file.c
231 DMA Fence Sync File uABI
237 Indefinite DMA Fences
252 are then imported as a DMA fence for integration into existing winsys
256 batch DMA fences for memory management instead of context preemption DMA
261 in-kernel DMA fences does not work, even when a fallback timeout is included to
264 * Only the kernel knows about all DMA fence dependencies, userspace is not aware
272 dependent upon DMA fences. If the kernel also support indefinite fences in the
273 kernel like a DMA fence, like any of the above proposal would, there is the
282 kernel [label="Kernel DMA Fences"]
300 * No future fences, proxy fences or userspace fences imported as DMA fences,
303 * No DMA fences that signal end of batchbuffer for command submission where
312 implications for DMA fences.
316 But memory allocations are not allowed to gate completion of DMA fences, which
317 means any workload using recoverable page faults cannot use DMA fences for
322 Linux rely on DMA fences, which means without an entirely new userspace stack
331 job with a DMA fence and a compute workload using recoverable page faults are
338 allocation is waiting for the DMA fence of the 3D workload to complete.
346 - DMA fence workloads and workloads which need page fault handling have
349 reservations for DMA fence workloads.
352 hardware resources for DMA fence workloads when they are in-flight. This must
353 cover the time from when the DMA fence is visible to other threads up to
358 requiring DMA fences or jobs requiring page fault handling: This means all DMA
360 inserted into the scheduler queue. And vice versa, before a DMA fence can be
366 memory blocks or runtime tracking of the full dependency graph of all DMA
373 GPUs do not have any impact. This allows us to keep using DMA fences internally
377 In some ways this page fault problem is a special case of the `Infinite DMA
379 depend on DMA fences, but not the other way around. And not even the page fault