DMABUF options
CONFIG_SYNC_FILE Explicit Synchronization Framework
The Sync File Framework adds explicit synchronization via userspace. It enables send/receive 'struct dma_fence' objects to/from userspace via Sync File fds for synchronization between drivers via userspace components. It has been ported from Android.
The first and main user for this is graphics in which a fence is associated with a buffer. When a job is submitted to the GPU a fence is attached to the buffer and is transferred via userspace, using Sync Files fds, to the DRM driver for example. More details at Documentation/driver-api/sync_file.rst.
- Selects
DMA_SHARED_BUFFER
If SYNC_FILE
CONFIG_SW_SYNC Sync File Validation Framework
A sync object driver that uses a 32bit counter to coordinate synchronization. Useful when there is no hardware primitive backing the synchronization.
WARNING: improper use of this can result in deadlocking kernel drivers from userspace. Intended for test and debug only.
CONFIG_UDMABUF userspace dmabuf misc driver
A driver to let userspace turn memfd regions into dma-bufs. Qemu can use this to create host dmabufs for guest framebuffers.
- Depends on
DMA_SHARED_BUFFER && (MEMFD_CREATE || COMPILE_TEST) &&
CONFIG_DMABUF_DEBUG DMA-BUF debug checks
This option enables additional checks for DMA-BUF importers and exporters. Specifically it validates that importers do not peek at the underlying struct page when they import a buffer.
- Depends on
DMA_SHARED_BUFFER
CONFIG_DMABUF_KUNIT_TEST KUnit tests for DMA-BUF
- Off
- Module
- Built in
Enable kunit tests for DMA-BUF
- Depends on
KUNIT - Selects
DMA_SHARED_BUFFER if KUNIT
CONFIG_DMABUF_HEAPS DMA-BUF Userland Memory Heaps
Choose this option to enable the DMA-BUF userland memory heaps. This options creates per heap chardevs in /dev/dma_heap/ which allows userspace to allocate dma-bufs that can be shared between drivers.
- Selects
DMA_SHARED_BUFFER
- arch/alpha/Kconfig:89
- arch/arc/Kconfig:70
- arch/arm/Kconfig:319
- arch/arm64/Kconfig:278
- arch/csky/Kconfig:160
- arch/hexagon/Kconfig:57
- arch/loongarch/Kconfig:787
- arch/m68k/Kconfig:84
- arch/microblaze/Kconfig:93
- arch/mips/Kconfig:3046
- arch/nios2/Kconfig:69
- arch/openrisc/Kconfig:54
- arch/parisc/Kconfig:106
- arch/powerpc/Kconfig:30
- arch/riscv/Kconfig:292
- arch/s390/Kconfig:2
- arch/sh/mm/Kconfig:4
- arch/sparc/Kconfig:140
- arch/um/Kconfig:52
- arch/x86/Kconfig:356
- arch/xtensa/Kconfig:94