| 1 | # SPDX-License-Identifier: GPL-2.0-only |
| 2 | # |
| 3 | # Drm device configuration |
| 4 | # |
| 5 | # This driver provides support for the |
| 6 | # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher. |
| 7 | # |
| 8 | menuconfig DRM |
| 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 |
| 12 | select HDMI |
| 13 | select I2C |
| 14 | select DMA_SHARED_BUFFER |
| 15 | select SYNC_FILE |
| 16 | # gallium uses SYS_kcmp for os_same_file_description() to de-duplicate |
| 17 | # device and dmabuf fd. Let's make sure that is available for our userspace. |
| 18 | select KCMP |
| 19 | select VIDEO |
| 20 | help |
| 21 | Kernel-level support for the Direct Rendering Infrastructure (DRI) |
| 22 | introduced in XFree86 4.0. If you say Y here, you need to select |
| 23 | the module that's right for your graphics card from the list below. |
| 24 | These modules provide support for synchronization, security, and |
| 25 | DMA transfers. Please see <http://dri.sourceforge.net/> for more |
| 26 | details. You should also select and configure AGP |
| 27 | (/dev/agpgart) support if it is available for your platform. |
| 28 | |
| 29 | menu "DRM debugging options" |
| 30 | depends on DRM |
| 31 | source "drivers/gpu/drm/Kconfig.debug" |
| 32 | endmenu |
| 33 | |
| 34 | if DRM |
| 35 | |
| 36 | config DRM_MIPI_DBI |
| 37 | tristate |
| 38 | depends on DRM |
| 39 | select DRM_KMS_HELPER |
| 40 | |
| 41 | config DRM_MIPI_DSI |
| 42 | bool |
| 43 | depends on DRM |
| 44 | |
| 45 | config DRM_KMS_HELPER |
| 46 | tristate |
| 47 | depends on DRM |
| 48 | select FB_CORE if DRM_FBDEV_EMULATION |
| 49 | help |
| 50 | CRTC helpers for KMS drivers. |
| 51 | |
| 52 | config DRM_DRAW |
| 53 | bool |
| 54 | depends on DRM |
| 55 | |
| 56 | config DRM_PANIC |
| 57 | bool "Display a user-friendly message when a kernel panic occurs" |
| 58 | depends on DRM && PRINTK |
| 59 | select FONT_SUPPORT |
| 60 | select DRM_DRAW |
| 61 | help |
| 62 | Enable a drm panic handler, which will display a user-friendly message |
| 63 | when a kernel panic occurs. It's useful when using a user-space |
| 64 | console instead of fbcon. |
| 65 | It will only work if your graphic driver supports this feature. |
| 66 | To support Hi-DPI Display, you can enable bigger fonts like |
| 67 | FONT_TER16x32 |
| 68 | |
| 69 | config DRM_PANIC_FOREGROUND_COLOR |
| 70 | hex "Drm panic screen foreground color, in RGB" |
| 71 | depends on DRM_PANIC |
| 72 | default 0xffffff |
| 73 | |
| 74 | config DRM_PANIC_BACKGROUND_COLOR |
| 75 | hex "Drm panic screen background color, in RGB" |
| 76 | depends on DRM_PANIC |
| 77 | default 0x000000 |
| 78 | |
| 79 | config DRM_PANIC_DEBUG |
| 80 | bool "Add a debug fs entry to trigger drm_panic" |
| 81 | depends on DRM_PANIC && DEBUG_FS |
| 82 | help |
| 83 | Add dri/[device]/drm_panic_plane_x in the kernel debugfs, to force the |
| 84 | panic handler to write the panic message to this plane scanout buffer. |
| 85 | This is unsafe and should not be enabled on a production build. |
| 86 | If in doubt, say "N". |
| 87 | |
| 88 | config DRM_PANIC_SCREEN |
| 89 | string "Panic screen formatter" |
| 90 | default "user" |
| 91 | depends on DRM_PANIC |
| 92 | help |
| 93 | This option enable to choose what will be displayed when a kernel |
| 94 | panic occurs. You can choose between "user", a short message telling |
| 95 | the user to reboot the system, or "kmsg" which will display the last |
| 96 | lines of kmsg. |
| 97 | This can also be overridden by drm.panic_screen=xxxx kernel parameter |
| 98 | or by writing to /sys/module/drm/parameters/panic_screen sysfs entry |
| 99 | Default is "user" |
| 100 | |
| 101 | config DRM_PANIC_SCREEN_QR_CODE |
| 102 | bool "Add a panic screen with a QR code" |
| 103 | depends on DRM_PANIC && RUST |
| 104 | select ZLIB_DEFLATE |
| 105 | help |
| 106 | This option adds a QR code generator, and a panic screen with a QR |
| 107 | code. The QR code will contain the last lines of kmsg and other debug |
| 108 | information. This should be easier for the user to report a kernel |
| 109 | panic, with all debug information available. |
| 110 | To use this panic screen, also set DRM_PANIC_SCREEN to "qr_code" |
| 111 | |
| 112 | config DRM_PANIC_SCREEN_QR_CODE_URL |
| 113 | string "Base URL of the QR code in the panic screen" |
| 114 | depends on DRM_PANIC_SCREEN_QR_CODE |
| 115 | help |
| 116 | This option sets the base URL to report the kernel panic. If it's set |
| 117 | the QR code will contain the URL and the kmsg compressed with zlib as |
| 118 | a URL parameter. If it's empty, the QR code will contain the kmsg as |
| 119 | uncompressed text only. |
| 120 | There is a demo code in javascript, to decode and uncompress the kmsg |
| 121 | data from the URL parameter at https://github.com/kdj0c/panic_report |
| 122 | |
| 123 | config DRM_PANIC_SCREEN_QR_VERSION |
| 124 | int "Maximum version (size) of the QR code." |
| 125 | depends on DRM_PANIC_SCREEN_QR_CODE |
| 126 | default 40 |
| 127 | help |
| 128 | This option limits the version (or size) of the QR code. QR code |
| 129 | version ranges from Version 1 (21x21) to Version 40 (177x177). |
| 130 | Smaller QR code are easier to read, but will contain less debugging |
| 131 | data. Default is 40. |
| 132 | |
| 133 | config DRM_RAS |
| 134 | bool "DRM RAS support" |
| 135 | depends on DRM |
| 136 | depends on NET |
| 137 | help |
| 138 | Enables the DRM RAS (Reliability, Availability and Serviceability) |
| 139 | support for DRM drivers. This provides a Generic Netlink interface |
| 140 | for error reporting and queries. |
| 141 | If in doubt, say "N". |
| 142 | |
| 143 | config DRM_DEBUG_DP_MST_TOPOLOGY_REFS |
| 144 | bool "Enable refcount backtrace history in the DP MST helpers" |
| 145 | depends on STACKTRACE_SUPPORT |
| 146 | select STACKDEPOT |
| 147 | select DRM_KMS_HELPER |
| 148 | depends on DEBUG_KERNEL |
| 149 | depends on EXPERT |
| 150 | help |
| 151 | Enables debug tracing for topology refs in DRM's DP MST helpers. A |
| 152 | history of each topology reference/dereference will be printed to the |
| 153 | kernel log once a port or branch device's topology refcount reaches 0. |
| 154 | |
| 155 | This has the potential to use a lot of memory and print some very |
| 156 | large kernel messages. If in doubt, say "N". |
| 157 | |
| 158 | config DRM_DEBUG_MODESET_LOCK |
| 159 | bool "Enable backtrace history for lock contention" |
| 160 | depends on STACKTRACE_SUPPORT |
| 161 | depends on DEBUG_KERNEL |
| 162 | depends on EXPERT |
| 163 | select STACKDEPOT |
| 164 | default y if DEBUG_WW_MUTEX_SLOWPATH |
| 165 | help |
| 166 | Enable debug tracing of failures to gracefully handle drm modeset lock |
| 167 | contention. A history of each drm modeset lock path hitting -EDEADLK |
| 168 | will be saved until gracefully handled, and the backtrace will be |
| 169 | printed when attempting to lock a contended lock. |
| 170 | |
| 171 | If in doubt, say "N". |
| 172 | |
| 173 | config DRM_CLIENT |
| 174 | bool |
| 175 | depends on DRM |
| 176 | help |
| 177 | Enables support for DRM clients. DRM drivers that need |
| 178 | struct drm_client_dev and its interfaces should select this |
| 179 | option. Drivers that support the default clients should |
| 180 | select DRM_CLIENT_SELECTION instead. |
| 181 | |
| 182 | source "drivers/gpu/drm/clients/Kconfig" |
| 183 | |
| 184 | config DRM_LOAD_EDID_FIRMWARE |
| 185 | bool "Allow to specify an EDID data set instead of probing for it" |
| 186 | depends on DRM |
| 187 | help |
| 188 | Say Y here, if you want to use EDID data to be loaded from the |
| 189 | /lib/firmware directory or one of the provided built-in |
| 190 | data sets. This may be necessary, if the graphics adapter or |
| 191 | monitor are unable to provide appropriate EDID data. Since this |
| 192 | feature is provided as a workaround for broken hardware, the |
| 193 | default case is N. Details and instructions how to build your own |
| 194 | EDID data are given in Documentation/admin-guide/edid.rst. |
| 195 | |
| 196 | source "drivers/gpu/drm/display/Kconfig" |
| 197 | |
| 198 | config DRM_TTM |
| 199 | tristate |
| 200 | depends on DRM && MMU |
| 201 | select SHMEM |
| 202 | help |
| 203 | GPU memory management subsystem for devices with multiple |
| 204 | GPU memory types. Will be enabled automatically if a device driver |
| 205 | uses it. |
| 206 | |
| 207 | config DRM_EXEC |
| 208 | tristate |
| 209 | depends on DRM |
| 210 | help |
| 211 | Execution context for command submissions |
| 212 | |
| 213 | config DRM_GPUVM |
| 214 | tristate |
| 215 | depends on DRM |
| 216 | select DRM_EXEC |
| 217 | help |
| 218 | GPU-VM representation providing helpers to manage a GPUs virtual |
| 219 | address space |
| 220 | |
| 221 | config RUST_DRM_GPUVM |
| 222 | bool |
| 223 | depends on DRM |
| 224 | select DRM_GPUVM |
| 225 | help |
| 226 | Choose this if you need GPUVM functions in Rust |
| 227 | |
| 228 | config DRM_GPUSVM |
| 229 | tristate |
| 230 | depends on DRM |
| 231 | select HMM_MIRROR |
| 232 | select MMU_NOTIFIER |
| 233 | help |
| 234 | GPU-SVM representation providing helpers to manage a GPUs shared |
| 235 | virtual memory |
| 236 | |
| 237 | config DRM_BUDDY |
| 238 | tristate |
| 239 | depends on DRM |
| 240 | select GPU_BUDDY |
| 241 | help |
| 242 | A page based buddy allocator |
| 243 | |
| 244 | config DRM_VRAM_HELPER |
| 245 | tristate |
| 246 | depends on DRM |
| 247 | help |
| 248 | Helpers for VRAM memory management |
| 249 | |
| 250 | config DRM_TTM_HELPER |
| 251 | tristate |
| 252 | depends on DRM |
| 253 | select DRM_TTM |
| 254 | select DRM_KMS_HELPER if DRM_FBDEV_EMULATION |
| 255 | select FB_CORE if DRM_FBDEV_EMULATION |
| 256 | select FB_SYSMEM_HELPERS_DEFERRED if DRM_FBDEV_EMULATION |
| 257 | help |
| 258 | Helpers for ttm-based gem objects |
| 259 | |
| 260 | config DRM_GEM_DMA_HELPER |
| 261 | tristate |
| 262 | depends on DRM |
| 263 | select DRM_KMS_HELPER if DRM_FBDEV_EMULATION |
| 264 | select FB_CORE if DRM_FBDEV_EMULATION |
| 265 | select FB_DMAMEM_HELPERS_DEFERRED if DRM_FBDEV_EMULATION |
| 266 | help |
| 267 | Choose this if you need the GEM DMA helper functions |
| 268 | |
| 269 | config DRM_GEM_SHMEM_HELPER |
| 270 | tristate |
| 271 | depends on DRM && MMU |
| 272 | select DRM_KMS_HELPER if DRM_FBDEV_EMULATION |
| 273 | select FB_CORE if DRM_FBDEV_EMULATION |
| 274 | select FB_SYSMEM_HELPERS_DEFERRED if DRM_FBDEV_EMULATION |
| 275 | help |
| 276 | Choose this if you need the GEM shmem helper functions |
| 277 | |
| 278 | config RUST_DRM_GEM_SHMEM_HELPER |
| 279 | bool |
| 280 | depends on DRM && MMU |
| 281 | select DRM_GEM_SHMEM_HELPER |
| 282 | help |
| 283 | Choose this if you need the GEM shmem helper functions In Rust |
| 284 | |
| 285 | config DRM_SUBALLOC_HELPER |
| 286 | tristate |
| 287 | depends on DRM |
| 288 | |
| 289 | config DRM_SCHED |
| 290 | tristate |
| 291 | depends on DRM |
| 292 | |
| 293 | # Separate option as not all DRM drivers use it |
| 294 | config DRM_PANEL_BACKLIGHT_QUIRKS |
| 295 | tristate |
| 296 | |
| 297 | config DRM_PRIVACY_SCREEN |
| 298 | bool |
| 299 | default n |
| 300 | |
| 301 | # DRM driver Kconfig files, sorted |
| 302 | source "drivers/gpu/drm/adp/Kconfig" |
| 303 | source "drivers/gpu/drm/amd/amdgpu/Kconfig" |
| 304 | source "drivers/gpu/drm/arm/Kconfig" |
| 305 | source "drivers/gpu/drm/armada/Kconfig" |
| 306 | source "drivers/gpu/drm/aspeed/Kconfig" |
| 307 | source "drivers/gpu/drm/ast/Kconfig" |
| 308 | source "drivers/gpu/drm/atmel-hlcdc/Kconfig" |
| 309 | source "drivers/gpu/drm/bridge/Kconfig" |
| 310 | source "drivers/gpu/drm/etnaviv/Kconfig" |
| 311 | source "drivers/gpu/drm/exynos/Kconfig" |
| 312 | source "drivers/gpu/drm/fsl-dcu/Kconfig" |
| 313 | source "drivers/gpu/drm/gma500/Kconfig" |
| 314 | source "drivers/gpu/drm/gud/Kconfig" |
| 315 | source "drivers/gpu/drm/hisilicon/Kconfig" |
| 316 | source "drivers/gpu/drm/hyperv/Kconfig" |
| 317 | source "drivers/gpu/drm/i915/Kconfig" |
| 318 | source "drivers/gpu/drm/imagination/Kconfig" |
| 319 | source "drivers/gpu/drm/imx/Kconfig" |
| 320 | source "drivers/gpu/drm/ingenic/Kconfig" |
| 321 | source "drivers/gpu/drm/kmb/Kconfig" |
| 322 | source "drivers/gpu/drm/lima/Kconfig" |
| 323 | source "drivers/gpu/drm/logicvc/Kconfig" |
| 324 | source "drivers/gpu/drm/loongson/Kconfig" |
| 325 | source "drivers/gpu/drm/mcde/Kconfig" |
| 326 | source "drivers/gpu/drm/mediatek/Kconfig" |
| 327 | source "drivers/gpu/drm/meson/Kconfig" |
| 328 | source "drivers/gpu/drm/mgag200/Kconfig" |
| 329 | source "drivers/gpu/drm/msm/Kconfig" |
| 330 | source "drivers/gpu/drm/mxsfb/Kconfig" |
| 331 | source "drivers/gpu/drm/nouveau/Kconfig" |
| 332 | source "drivers/gpu/drm/nova/Kconfig" |
| 333 | source "drivers/gpu/drm/omapdrm/Kconfig" |
| 334 | source "drivers/gpu/drm/panel/Kconfig" |
| 335 | source "drivers/gpu/drm/panfrost/Kconfig" |
| 336 | source "drivers/gpu/drm/panthor/Kconfig" |
| 337 | source "drivers/gpu/drm/pl111/Kconfig" |
| 338 | source "drivers/gpu/drm/qxl/Kconfig" |
| 339 | source "drivers/gpu/drm/radeon/Kconfig" |
| 340 | source "drivers/gpu/drm/renesas/Kconfig" |
| 341 | source "drivers/gpu/drm/rockchip/Kconfig" |
| 342 | source "drivers/gpu/drm/sitronix/Kconfig" |
| 343 | source "drivers/gpu/drm/solomon/Kconfig" |
| 344 | source "drivers/gpu/drm/sprd/Kconfig" |
| 345 | source "drivers/gpu/drm/sti/Kconfig" |
| 346 | source "drivers/gpu/drm/stm/Kconfig" |
| 347 | source "drivers/gpu/drm/sun4i/Kconfig" |
| 348 | source "drivers/gpu/drm/sysfb/Kconfig" |
| 349 | source "drivers/gpu/drm/tegra/Kconfig" |
| 350 | source "drivers/gpu/drm/tidss/Kconfig" |
| 351 | source "drivers/gpu/drm/tilcdc/Kconfig" |
| 352 | source "drivers/gpu/drm/tiny/Kconfig" |
| 353 | source "drivers/gpu/drm/tve200/Kconfig" |
| 354 | source "drivers/gpu/drm/tyr/Kconfig" |
| 355 | source "drivers/gpu/drm/udl/Kconfig" |
| 356 | source "drivers/gpu/drm/v3d/Kconfig" |
| 357 | source "drivers/gpu/drm/vboxvideo/Kconfig" |
| 358 | source "drivers/gpu/drm/vc4/Kconfig" |
| 359 | source "drivers/gpu/drm/verisilicon/Kconfig" |
| 360 | source "drivers/gpu/drm/vgem/Kconfig" |
| 361 | source "drivers/gpu/drm/virtio/Kconfig" |
| 362 | source "drivers/gpu/drm/vkms/Kconfig" |
| 363 | source "drivers/gpu/drm/vmwgfx/Kconfig" |
| 364 | source "drivers/gpu/drm/xe/Kconfig" |
| 365 | source "drivers/gpu/drm/xen/Kconfig" |
| 366 | source "drivers/gpu/drm/xlnx/Kconfig" |
| 367 | |
| 368 | endif |
| 369 | |
| 370 | # Separate option because drm_panel_orientation_quirks.c is shared with fbdev |
| 371 | config DRM_PANEL_ORIENTATION_QUIRKS |
| 372 | tristate |