1 # SPDX-License-Identifier: GPL-2.0-only
3 # Drm device configuration
5 # This driver provides support for the
6 # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher.
9 tristate "Direct Rendering Manager (XFree86 4.1.0 and higher DRI support)"
10 depends on (AGP || AGP=n) && !EMULATED_CMPXCHG && HAS_DMA
11 select DRM_PANEL_ORIENTATION_QUIRKS
16 select DMA_SHARED_BUFFER
18 # gallium uses SYS_kcmp for os_same_file_description() to de-duplicate
19 # device and dmabuf fd. Let's make sure that is available for our userspace.
21 select VIDEO_NOMODESET
23 Kernel-level support for the Direct Rendering Infrastructure (DRI)
24 introduced in XFree86 4.0. If you say Y here, you need to select
25 the module that's right for your graphics card from the list below.
26 These modules provide support for synchronization, security, and
27 DMA transfers. Please see <http://dri.sourceforge.net/> for more
28 details. You should also select and configure AGP
29 (/dev/agpgart) support if it is available for your platform.
41 bool "Insert extra checks and debug info into the DRM range managers"
44 depends on STACKTRACE_SUPPORT
47 Enable allocation tracking of memory manager and leak detection on
50 Recommended for driver developers only.
54 config DRM_USE_DYNAMIC_DEBUG
55 bool "use dynamic debug to implement drm.debug"
58 depends on DYNAMIC_DEBUG || DYNAMIC_DEBUG_CORE
61 Use dynamic-debug to avoid drm_debug_enabled() runtime overheads.
62 Due to callsite counts in DRM drivers (~4k in amdgpu) and 56
63 bytes per callsite, the .data costs can be substantial, and
64 are therefore configurable.
67 tristate "KUnit tests for DRM" if !KUNIT_ALL_TESTS
68 depends on DRM && KUNIT
70 select DRM_DISPLAY_DP_HELPER
71 select DRM_DISPLAY_HELPER
75 select DRM_EXPORT_FOR_TESTS if m
76 default KUNIT_ALL_TESTS
78 This builds unit tests for DRM. This option is not useful for
79 distributions or general kernels, but only for kernel
80 developers working on DRM and associated drivers.
82 For more information on KUnit and unit tests in general,
83 please refer to the KUnit documentation in
84 Documentation/dev-tools/kunit/.
92 CRTC helpers for KMS drivers.
94 config DRM_DEBUG_DP_MST_TOPOLOGY_REFS
95 bool "Enable refcount backtrace history in the DP MST helpers"
96 depends on STACKTRACE_SUPPORT
98 depends on DRM_KMS_HELPER
99 depends on DEBUG_KERNEL
102 Enables debug tracing for topology refs in DRM's DP MST helpers. A
103 history of each topology reference/dereference will be printed to the
104 kernel log once a port or branch device's topology refcount reaches 0.
106 This has the potential to use a lot of memory and print some very
107 large kernel messages. If in doubt, say "N".
109 config DRM_DEBUG_MODESET_LOCK
110 bool "Enable backtrace history for lock contention"
111 depends on STACKTRACE_SUPPORT
112 depends on DEBUG_KERNEL
115 default y if DEBUG_WW_MUTEX_SLOWPATH
117 Enable debug tracing of failures to gracefully handle drm modeset lock
118 contention. A history of each drm modeset lock path hitting -EDEADLK
119 will be saved until gracefully handled, and the backtrace will be
120 printed when attempting to lock a contended lock.
122 If in doubt, say "N".
124 config DRM_FBDEV_EMULATION
125 bool "Enable legacy fbdev support for your modesetting driver"
126 depends on DRM_KMS_HELPER
127 depends on FB=y || FB=DRM_KMS_HELPER
128 select FB_CFB_FILLRECT
129 select FB_CFB_COPYAREA
130 select FB_CFB_IMAGEBLIT
131 select FB_DEFERRED_IO
133 select FB_SYS_FILLRECT
134 select FB_SYS_COPYAREA
135 select FB_SYS_IMAGEBLIT
136 select FRAMEBUFFER_CONSOLE if !EXPERT
137 select FRAMEBUFFER_CONSOLE_DETECT_PRIMARY if FRAMEBUFFER_CONSOLE
140 Choose this option if you have a need for the legacy fbdev
141 support. Note that this support also provides the linux console
142 support on top of your modesetting driver.
144 If in doubt, say "Y".
146 config DRM_FBDEV_OVERALLOC
147 int "Overallocation of the fbdev buffer"
148 depends on DRM_FBDEV_EMULATION
151 Defines the fbdev buffer overallocation in percent. Default
152 is 100. Typical values for double buffering will be 200,
153 triple buffering 300.
155 config DRM_FBDEV_LEAK_PHYS_SMEM
156 bool "Shamelessly allow leaking of fbdev physical address (DANGEROUS)"
157 depends on DRM_FBDEV_EMULATION && EXPERT
160 In order to keep user-space compatibility, we want in certain
161 use-cases to keep leaking the fbdev physical address to the
162 user-space program handling the fbdev buffer.
163 This affects, not only, Amlogic, Allwinner or Rockchip devices
164 with ARM Mali GPUs using an userspace Blob.
165 This option is not supported by upstream developers and should be
166 removed as soon as possible and be considered as a broken and
167 legacy behaviour from a modern fbdev device driver.
169 Please send any bug reports when using this to your proprietary
170 software vendor that requires this.
172 If in doubt, say "N" or spread the word to your closed source
175 config DRM_LOAD_EDID_FIRMWARE
176 bool "Allow to specify an EDID data set instead of probing for it"
179 Say Y here, if you want to use EDID data to be loaded from the
180 /lib/firmware directory or one of the provided built-in
181 data sets. This may be necessary, if the graphics adapter or
182 monitor are unable to provide appropriate EDID data. Since this
183 feature is provided as a workaround for broken hardware, the
184 default case is N. Details and instructions how to build your own
185 EDID data are given in Documentation/admin-guide/edid.rst.
187 source "drivers/gpu/drm/display/Kconfig"
191 depends on DRM && MMU
193 GPU memory management subsystem for devices with multiple
194 GPU memory types. Will be enabled automatically if a device driver
201 A page based buddy allocator
203 config DRM_VRAM_HELPER
207 Helpers for VRAM memory management
209 config DRM_TTM_HELPER
214 Helpers for ttm-based gem objects
216 config DRM_GEM_DMA_HELPER
220 Choose this if you need the GEM DMA helper functions
222 config DRM_GEM_SHMEM_HELPER
224 depends on DRM && MMU
226 Choose this if you need the GEM shmem helper functions
232 source "drivers/gpu/drm/i2c/Kconfig"
234 source "drivers/gpu/drm/arm/Kconfig"
236 source "drivers/gpu/drm/radeon/Kconfig"
238 source "drivers/gpu/drm/amd/amdgpu/Kconfig"
240 source "drivers/gpu/drm/nouveau/Kconfig"
242 source "drivers/gpu/drm/i915/Kconfig"
244 source "drivers/gpu/drm/kmb/Kconfig"
247 tristate "Virtual GEM provider"
248 depends on DRM && MMU
249 select DRM_GEM_SHMEM_HELPER
251 Choose this option to get a virtual graphics memory manager,
252 as used by Mesa's software renderer for enhanced performance.
253 If M is selected the module will be called vgem.
256 tristate "Virtual KMS (EXPERIMENTAL)"
257 depends on DRM && MMU
258 select DRM_KMS_HELPER
259 select DRM_GEM_SHMEM_HELPER
263 Virtual Kernel Mode-Setting (VKMS) is used for testing or for
264 running GPU in a headless machines. Choose this option to get
267 If M is selected the module will be called vkms.
269 source "drivers/gpu/drm/exynos/Kconfig"
271 source "drivers/gpu/drm/rockchip/Kconfig"
273 source "drivers/gpu/drm/vmwgfx/Kconfig"
275 source "drivers/gpu/drm/gma500/Kconfig"
277 source "drivers/gpu/drm/udl/Kconfig"
279 source "drivers/gpu/drm/ast/Kconfig"
281 source "drivers/gpu/drm/mgag200/Kconfig"
283 source "drivers/gpu/drm/armada/Kconfig"
285 source "drivers/gpu/drm/atmel-hlcdc/Kconfig"
287 source "drivers/gpu/drm/rcar-du/Kconfig"
289 source "drivers/gpu/drm/shmobile/Kconfig"
291 source "drivers/gpu/drm/sun4i/Kconfig"
293 source "drivers/gpu/drm/omapdrm/Kconfig"
295 source "drivers/gpu/drm/tilcdc/Kconfig"
297 source "drivers/gpu/drm/qxl/Kconfig"
299 source "drivers/gpu/drm/virtio/Kconfig"
301 source "drivers/gpu/drm/msm/Kconfig"
303 source "drivers/gpu/drm/fsl-dcu/Kconfig"
305 source "drivers/gpu/drm/tegra/Kconfig"
307 source "drivers/gpu/drm/stm/Kconfig"
309 source "drivers/gpu/drm/panel/Kconfig"
311 source "drivers/gpu/drm/bridge/Kconfig"
313 source "drivers/gpu/drm/sti/Kconfig"
315 source "drivers/gpu/drm/imx/Kconfig"
317 source "drivers/gpu/drm/ingenic/Kconfig"
319 source "drivers/gpu/drm/v3d/Kconfig"
321 source "drivers/gpu/drm/vc4/Kconfig"
323 source "drivers/gpu/drm/etnaviv/Kconfig"
325 source "drivers/gpu/drm/hisilicon/Kconfig"
327 source "drivers/gpu/drm/logicvc/Kconfig"
329 source "drivers/gpu/drm/mediatek/Kconfig"
331 source "drivers/gpu/drm/mxsfb/Kconfig"
333 source "drivers/gpu/drm/meson/Kconfig"
335 source "drivers/gpu/drm/tiny/Kconfig"
337 source "drivers/gpu/drm/pl111/Kconfig"
339 source "drivers/gpu/drm/tve200/Kconfig"
341 source "drivers/gpu/drm/xen/Kconfig"
343 source "drivers/gpu/drm/vboxvideo/Kconfig"
345 source "drivers/gpu/drm/lima/Kconfig"
347 source "drivers/gpu/drm/panfrost/Kconfig"
349 source "drivers/gpu/drm/aspeed/Kconfig"
351 source "drivers/gpu/drm/mcde/Kconfig"
353 source "drivers/gpu/drm/tidss/Kconfig"
355 source "drivers/gpu/drm/xlnx/Kconfig"
357 source "drivers/gpu/drm/gud/Kconfig"
359 source "drivers/gpu/drm/solomon/Kconfig"
361 source "drivers/gpu/drm/sprd/Kconfig"
364 tristate "DRM Support for Hyper-V synthetic video device"
365 depends on DRM && PCI && MMU && HYPERV
366 select DRM_KMS_HELPER
367 select DRM_GEM_SHMEM_HELPER
369 This is a KMS driver for Hyper-V synthetic video device. Choose this
370 option if you would like to enable drm driver for Hyper-V virtual
371 machine. Unselect Hyper-V framebuffer driver (CONFIG_FB_HYPERV) so
372 that DRM driver is used by default.
374 If M is selected the module will be called hyperv_drm.
376 # Keep legacy drivers last
378 menuconfig DRM_LEGACY
379 bool "Enable legacy drivers (DANGEROUS)"
380 depends on DRM && MMU
382 Enable legacy DRI1 drivers. Those drivers expose unsafe and dangerous
383 APIs to user-space, which can be used to circumvent access
384 restrictions and other security measures. For backwards compatibility
385 those drivers are still available, but their use is highly
386 inadvisable and might harm your system.
388 You are recommended to use the safe modeset-only drivers instead, and
389 perform 3D emulation in user-space.
391 Unless you have strong reasons to go rogue, say "N".
396 tristate "3dfx Banshee/Voodoo3+"
397 depends on DRM && PCI
399 Choose this option if you have a 3dfx Banshee or Voodoo3 (or later),
400 graphics card. If M is selected, the module will be called tdfx.
403 tristate "ATI Rage 128"
404 depends on DRM && PCI
407 Choose this option if you have an ATI Rage 128 graphics card. If M
408 is selected, the module will be called r128. AGP support for
409 this card is strongly suggested (unless you have a PCI version).
412 tristate "Intel I810"
413 # !PREEMPTION because of missing ioctl locking
414 depends on DRM && AGP && AGP_INTEL && (!PREEMPTION || BROKEN)
416 Choose this option if you have an Intel I810 graphics card. If M is
417 selected, the module will be called i810. AGP support is required
418 for this driver to work.
421 tristate "Matrox g200/g400"
422 depends on DRM && PCI
425 Choose this option if you have a Matrox G200, G400 or G450 graphics
426 card. If M is selected, the module will be called mga. AGP
427 support is required for this driver to work.
430 tristate "SiS video cards"
431 depends on DRM && AGP
432 depends on FB_SIS || FB_SIS=n
434 Choose this option if you have a SiS 630 or compatible video
435 chipset. If M is selected the module will be called sis. AGP
436 support is required for this driver to work.
439 tristate "Via unichrome video cards"
440 depends on DRM && PCI
442 Choose this option if you have a Via unichrome or compatible video
443 chipset. If M is selected the module will be called via.
446 tristate "Savage video cards"
447 depends on DRM && PCI
449 Choose this option if you have a Savage3D/4/SuperSavage/Pro/Twister
450 chipset. If M is selected the module will be called savage.
454 config DRM_EXPORT_FOR_TESTS
457 # Separate option because drm_panel_orientation_quirks.c is shared with fbdev
458 config DRM_PANEL_ORIENTATION_QUIRKS
461 config DRM_LIB_RANDOM
465 config DRM_PRIVACY_SCREEN