1============================= 2Mode Setting Helper Functions 3============================= 4 5The DRM subsystem aims for a strong separation between core code and helper 6libraries. Core code takes care of general setup and teardown and decoding 7userspace requests to kernel internal objects. Everything else is handled by a 8large set of helper libraries, which can be combined freely to pick and choose 9for each driver what fits, and avoid shared code where special behaviour is 10needed. 11 12This distinction between core code and helpers is especially strong in the 13modesetting code, where there's a shared userspace ABI for all drivers. This is 14in contrast to the render side, where pretty much everything (with very few 15exceptions) can be considered optional helper code. 16 17There are a few areas these helpers can grouped into: 18 19* Helpers to implement modesetting. The important ones here are the atomic 20 helpers. Old drivers still often use the legacy CRTC helpers. They both share 21 the same set of common helper vtables. For really simple drivers (anything 22 that would have been a great fit in the deprecated fbdev subsystem) there's 23 also the simple display pipe helpers. 24 25* There's a big pile of helpers for handling outputs. First the generic bridge 26 helpers for handling encoder and transcoder IP blocks. Second the panel helpers 27 for handling panel-related information and logic. Plus then a big set of 28 helpers for the various sink standards (DisplayPort, HDMI, MIPI DSI). Finally 29 there's also generic helpers for handling output probing, and for dealing with 30 EDIDs. 31 32* The last group of helpers concerns itself with the frontend side of a display 33 pipeline: Planes, handling rectangles for visibility checking and scissoring, 34 flip queues and assorted bits. 35 36Modeset Helper Reference for Common Vtables 37=========================================== 38 39.. kernel-doc:: include/drm/drm_modeset_helper_vtables.h 40 :doc: overview 41 42.. kernel-doc:: include/drm/drm_modeset_helper_vtables.h 43 :internal: 44 45.. _drm_atomic_helper: 46 47Atomic Modeset Helper Functions Reference 48========================================= 49 50Overview 51-------- 52 53.. kernel-doc:: drivers/gpu/drm/drm_atomic_helper.c 54 :doc: overview 55 56Implementing Asynchronous Atomic Commit 57--------------------------------------- 58 59.. kernel-doc:: drivers/gpu/drm/drm_atomic_helper.c 60 :doc: implementing nonblocking commit 61 62Helper Functions Reference 63-------------------------- 64 65.. kernel-doc:: include/drm/drm_atomic_helper.h 66 :internal: 67 68.. kernel-doc:: drivers/gpu/drm/drm_atomic_helper.c 69 :export: 70 71Atomic State Reset and Initialization 72------------------------------------- 73 74.. kernel-doc:: drivers/gpu/drm/drm_atomic_state_helper.c 75 :doc: atomic state reset and initialization 76 77Atomic State Helper Reference 78----------------------------- 79 80.. kernel-doc:: drivers/gpu/drm/drm_atomic_state_helper.c 81 :export: 82 83GEM Atomic Helper Reference 84--------------------------- 85 86.. kernel-doc:: drivers/gpu/drm/drm_gem_atomic_helper.c 87 :doc: overview 88 89.. kernel-doc:: include/drm/drm_gem_atomic_helper.h 90 :internal: 91 92.. kernel-doc:: drivers/gpu/drm/drm_gem_atomic_helper.c 93 :export: 94 95Simple KMS Helper Reference 96=========================== 97 98.. kernel-doc:: drivers/gpu/drm/drm_simple_kms_helper.c 99 :doc: overview 100 101.. kernel-doc:: include/drm/drm_simple_kms_helper.h 102 :internal: 103 104.. kernel-doc:: drivers/gpu/drm/drm_simple_kms_helper.c 105 :export: 106 107fbdev Helper Functions Reference 108================================ 109 110.. kernel-doc:: drivers/gpu/drm/drm_fb_helper.c 111 :doc: fbdev helpers 112 113.. kernel-doc:: include/drm/drm_fb_helper.h 114 :internal: 115 116.. kernel-doc:: drivers/gpu/drm/drm_fb_helper.c 117 :export: 118 119.. kernel-doc:: drivers/gpu/drm/drm_fbdev_generic.c 120 :export: 121 122format Helper Functions Reference 123================================= 124 125.. kernel-doc:: drivers/gpu/drm/drm_format_helper.c 126 :export: 127 128Framebuffer DMA Helper Functions Reference 129========================================== 130 131.. kernel-doc:: drivers/gpu/drm/drm_fb_dma_helper.c 132 :doc: framebuffer dma helper functions 133 134.. kernel-doc:: drivers/gpu/drm/drm_fb_dma_helper.c 135 :export: 136 137Framebuffer GEM Helper Reference 138================================ 139 140.. kernel-doc:: drivers/gpu/drm/drm_gem_framebuffer_helper.c 141 :doc: overview 142 143.. kernel-doc:: drivers/gpu/drm/drm_gem_framebuffer_helper.c 144 :export: 145 146.. _drm_bridges: 147 148Bridges 149======= 150 151Overview 152-------- 153 154.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 155 :doc: overview 156 157Display Driver Integration 158-------------------------- 159 160.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 161 :doc: display driver integration 162 163Special Care with MIPI-DSI bridges 164---------------------------------- 165 166.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 167 :doc: special care dsi 168 169Bridge Operations 170----------------- 171 172.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 173 :doc: bridge operations 174 175Bridge Connector Helper 176----------------------- 177 178.. kernel-doc:: drivers/gpu/drm/drm_bridge_connector.c 179 :doc: overview 180 181 182Bridge Helper Reference 183------------------------- 184 185.. kernel-doc:: include/drm/drm_bridge.h 186 :internal: 187 188.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 189 :export: 190 191MIPI-DSI bridge operation 192------------------------- 193 194.. kernel-doc:: drivers/gpu/drm/drm_bridge.c 195 :doc: dsi bridge operations 196 197 198Bridge Connector Helper Reference 199--------------------------------- 200 201.. kernel-doc:: drivers/gpu/drm/drm_bridge_connector.c 202 :export: 203 204Panel-Bridge Helper Reference 205----------------------------- 206 207.. kernel-doc:: drivers/gpu/drm/bridge/panel.c 208 :export: 209 210.. _drm_panel_helper: 211 212Panel Helper Reference 213====================== 214 215.. kernel-doc:: drivers/gpu/drm/drm_panel.c 216 :doc: drm panel 217 218.. kernel-doc:: include/drm/drm_panel.h 219 :internal: 220 221.. kernel-doc:: drivers/gpu/drm/drm_panel.c 222 :export: 223 224.. kernel-doc:: drivers/gpu/drm/drm_panel_orientation_quirks.c 225 :export: 226 227Panel Self Refresh Helper Reference 228=================================== 229 230.. kernel-doc:: drivers/gpu/drm/drm_self_refresh_helper.c 231 :doc: overview 232 233.. kernel-doc:: drivers/gpu/drm/drm_self_refresh_helper.c 234 :export: 235 236HDCP Helper Functions Reference 237=============================== 238 239.. kernel-doc:: drivers/gpu/drm/display/drm_hdcp_helper.c 240 :export: 241 242Display Port Helper Functions Reference 243======================================= 244 245.. kernel-doc:: drivers/gpu/drm/display/drm_dp_helper.c 246 :doc: dp helpers 247 248.. kernel-doc:: include/drm/display/drm_dp.h 249 :internal: 250 251.. kernel-doc:: include/drm/display/drm_dp_helper.h 252 :internal: 253 254.. kernel-doc:: drivers/gpu/drm/display/drm_dp_helper.c 255 :export: 256 257Display Port CEC Helper Functions Reference 258=========================================== 259 260.. kernel-doc:: drivers/gpu/drm/display/drm_dp_cec.c 261 :doc: dp cec helpers 262 263.. kernel-doc:: drivers/gpu/drm/display/drm_dp_cec.c 264 :export: 265 266Display Port Dual Mode Adaptor Helper Functions Reference 267========================================================= 268 269.. kernel-doc:: drivers/gpu/drm/display/drm_dp_dual_mode_helper.c 270 :doc: dp dual mode helpers 271 272.. kernel-doc:: include/drm/display/drm_dp_dual_mode_helper.h 273 :internal: 274 275.. kernel-doc:: drivers/gpu/drm/display/drm_dp_dual_mode_helper.c 276 :export: 277 278Display Port MST Helpers 279======================== 280 281Overview 282-------- 283 284.. kernel-doc:: drivers/gpu/drm/display/drm_dp_mst_topology.c 285 :doc: dp mst helper 286 287.. kernel-doc:: drivers/gpu/drm/display/drm_dp_mst_topology.c 288 :doc: Branch device and port refcounting 289 290Functions Reference 291------------------- 292 293.. kernel-doc:: include/drm/display/drm_dp_mst_helper.h 294 :internal: 295 296.. kernel-doc:: drivers/gpu/drm/display/drm_dp_mst_topology.c 297 :export: 298 299Topology Lifetime Internals 300--------------------------- 301 302These functions aren't exported to drivers, but are documented here to help make 303the MST topology helpers easier to understand 304 305.. kernel-doc:: drivers/gpu/drm/display/drm_dp_mst_topology.c 306 :functions: drm_dp_mst_topology_try_get_mstb drm_dp_mst_topology_get_mstb 307 drm_dp_mst_topology_put_mstb 308 drm_dp_mst_topology_try_get_port drm_dp_mst_topology_get_port 309 drm_dp_mst_topology_put_port 310 drm_dp_mst_get_mstb_malloc drm_dp_mst_put_mstb_malloc 311 312MIPI DBI Helper Functions Reference 313=================================== 314 315.. kernel-doc:: drivers/gpu/drm/drm_mipi_dbi.c 316 :doc: overview 317 318.. kernel-doc:: include/drm/drm_mipi_dbi.h 319 :internal: 320 321.. kernel-doc:: drivers/gpu/drm/drm_mipi_dbi.c 322 :export: 323 324MIPI DSI Helper Functions Reference 325=================================== 326 327.. kernel-doc:: drivers/gpu/drm/drm_mipi_dsi.c 328 :doc: dsi helpers 329 330.. kernel-doc:: include/drm/drm_mipi_dsi.h 331 :internal: 332 333.. kernel-doc:: drivers/gpu/drm/drm_mipi_dsi.c 334 :export: 335 336Display Stream Compression Helper Functions Reference 337===================================================== 338 339.. kernel-doc:: drivers/gpu/drm/display/drm_dsc_helper.c 340 :doc: dsc helpers 341 342.. kernel-doc:: include/drm/display/drm_dsc.h 343 :internal: 344 345.. kernel-doc:: drivers/gpu/drm/display/drm_dsc_helper.c 346 :export: 347 348Output Probing Helper Functions Reference 349========================================= 350 351.. kernel-doc:: drivers/gpu/drm/drm_probe_helper.c 352 :doc: output probing helper overview 353 354.. kernel-doc:: drivers/gpu/drm/drm_probe_helper.c 355 :export: 356 357EDID Helper Functions Reference 358=============================== 359 360.. kernel-doc:: include/drm/drm_edid.h 361 :internal: 362 363.. kernel-doc:: drivers/gpu/drm/drm_edid.c 364 :export: 365 366SCDC Helper Functions Reference 367=============================== 368 369.. kernel-doc:: drivers/gpu/drm/display/drm_scdc_helper.c 370 :doc: scdc helpers 371 372.. kernel-doc:: include/drm/display/drm_scdc_helper.h 373 :internal: 374 375.. kernel-doc:: drivers/gpu/drm/display/drm_scdc_helper.c 376 :export: 377 378HDMI Infoframes Helper Reference 379================================ 380 381Strictly speaking this is not a DRM helper library but generally usable 382by any driver interfacing with HDMI outputs like v4l or alsa drivers. 383But it nicely fits into the overall topic of mode setting helper 384libraries and hence is also included here. 385 386.. kernel-doc:: include/linux/hdmi.h 387 :internal: 388 389.. kernel-doc:: drivers/video/hdmi.c 390 :export: 391 392Rectangle Utilities Reference 393============================= 394 395.. kernel-doc:: include/drm/drm_rect.h 396 :doc: rect utils 397 398.. kernel-doc:: include/drm/drm_rect.h 399 :internal: 400 401.. kernel-doc:: drivers/gpu/drm/drm_rect.c 402 :export: 403 404Flip-work Helper Reference 405========================== 406 407.. kernel-doc:: include/drm/drm_flip_work.h 408 :doc: flip utils 409 410.. kernel-doc:: include/drm/drm_flip_work.h 411 :internal: 412 413.. kernel-doc:: drivers/gpu/drm/drm_flip_work.c 414 :export: 415 416Auxiliary Modeset Helpers 417========================= 418 419.. kernel-doc:: drivers/gpu/drm/drm_modeset_helper.c 420 :doc: aux kms helpers 421 422.. kernel-doc:: drivers/gpu/drm/drm_modeset_helper.c 423 :export: 424 425OF/DT Helpers 426============= 427 428.. kernel-doc:: drivers/gpu/drm/drm_of.c 429 :doc: overview 430 431.. kernel-doc:: drivers/gpu/drm/drm_of.c 432 :export: 433 434Legacy Plane Helper Reference 435============================= 436 437.. kernel-doc:: drivers/gpu/drm/drm_plane_helper.c 438 :doc: overview 439 440.. kernel-doc:: drivers/gpu/drm/drm_plane_helper.c 441 :export: 442 443Legacy CRTC/Modeset Helper Functions Reference 444============================================== 445 446.. kernel-doc:: drivers/gpu/drm/drm_crtc_helper.c 447 :doc: overview 448 449.. kernel-doc:: drivers/gpu/drm/drm_crtc_helper.c 450 :export: 451 452Privacy-screen class 453==================== 454 455.. kernel-doc:: drivers/gpu/drm/drm_privacy_screen.c 456 :doc: overview 457 458.. kernel-doc:: include/drm/drm_privacy_screen_driver.h 459 :internal: 460 461.. kernel-doc:: include/drm/drm_privacy_screen_machine.h 462 :internal: 463 464.. kernel-doc:: drivers/gpu/drm/drm_privacy_screen.c 465 :export: 466