1 # SPDX-License-Identifier: GPL-2.0-only
5 bool "Explicit Synchronization Framework"
7 select DMA_SHARED_BUFFER
9 The Sync File Framework adds explicit synchronization via
10 userspace. It enables send/receive 'struct dma_fence' objects to/from
11 userspace via Sync File fds for synchronization between drivers via
12 userspace components. It has been ported from Android.
14 The first and main user for this is graphics in which a fence is
15 associated with a buffer. When a job is submitted to the GPU a fence
16 is attached to the buffer and is transferred via userspace, using Sync
17 Files fds, to the DRM driver for example. More details at
18 Documentation/driver-api/sync_file.rst.
21 bool "Sync File Validation Framework"
26 A sync object driver that uses a 32bit counter to coordinate
27 synchronization. Useful when there is no hardware primitive backing
30 WARNING: improper use of this can result in deadlocking kernel
31 drivers from userspace. Intended for test and debug only.
34 bool "userspace dmabuf misc driver"
36 depends on DMA_SHARED_BUFFER
37 depends on MEMFD_CREATE || COMPILE_TEST
39 A driver to let userspace turn memfd regions into dma-bufs.
40 Qemu can use this to create host dmabufs for guest framebuffers.
42 config DMABUF_MOVE_NOTIFY
43 bool "Move notify between drivers (EXPERIMENTAL)"
46 Don't pin buffers if the dynamic DMA-buf interface is available on
47 both the exporter as well as the importer. This fixes a security
48 problem where userspace is able to pin unrestricted amounts of memory
50 This is marked experimental because we don't yet have a consistent
51 execution context and memory management between drivers.
53 config DMABUF_SELFTESTS
54 tristate "Selftests for the dma-buf interfaces"
56 depends on DMA_SHARED_BUFFER
58 menuconfig DMABUF_HEAPS
59 bool "DMA-BUF Userland Memory Heaps"
60 select DMA_SHARED_BUFFER
62 Choose this option to enable the DMA-BUF userland memory heaps.
63 This options creates per heap chardevs in /dev/dma_heap/ which
64 allows userspace to allocate dma-bufs that can be shared
67 source "drivers/dma-buf/heaps/Kconfig"