aboutsummaryrefslogtreecommitdiff
path: root/Documentation/dma-buf.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/dma-buf.rst')
-rw-r--r--Documentation/dma-buf.rst74
1 files changed, 74 insertions, 0 deletions
diff --git a/Documentation/dma-buf.rst b/Documentation/dma-buf.rst
new file mode 100644
index 000000000000..939d1ad1075e
--- /dev/null
+++ b/Documentation/dma-buf.rst
@@ -0,0 +1,74 @@
+==================================
+Buffer Sharing and Synchronization
+==================================
+
+
+Introduction
+------------
+
+The dma-buf subsystem provides the framework for sharing buffers for
+hardware (DMA) access across multiple device drivers and subsystems, and
+for synchronizing asynchronous hardware access.
+
+This is used, for example, by drm "prime" multi-GPU support, but is of
+course not limited to GPU use cases.
+
+The three main components of this are:
+
+* dma-buf_: represents an sg_table, and is exposed to userspace as a file
+ descriptor to allow passing between devices,
+
+* fence_: which provides a mechanism to signal when one device has finished
+ access, and
+
+* reservation_: manages the shared or exclusive fence(s) associated with the
+ buffer.
+
+.. _dma-buf:
+
+dma-buf
+~~~~~~~
+
+.. kernel-doc:: drivers/dma-buf/dma-buf.c
+ :export:
+
+.. kernel-doc:: include/linux/dma-buf.h
+ :internal:
+
+.. _fence:
+
+fence
+~~~~~
+
+.. kernel-doc:: drivers/dma-buf/fence.c
+ :export:
+
+.. kernel-doc:: include/linux/fence.h
+ :internal:
+
+.. kernel-doc:: drivers/dma-buf/seqno-fence.c
+ :export:
+
+.. kernel-doc:: include/linux/seqno-fence.h
+ :internal:
+
+.. kernel-doc:: drivers/dma-buf/sync_file.c
+ :export:
+
+.. kernel-doc:: include/linux/sync_file.h
+ :internal:
+
+.. _reservation:
+
+reservation
+~~~~~~~~~~~
+
+.. kernel-doc:: drivers/dma-buf/reservation.c
+ :doc: Reservation Object Overview
+
+.. kernel-doc:: drivers/dma-buf/reservation.c
+ :export:
+
+.. kernel-doc:: include/linux/reservation.h
+ :internal:
+