1<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>struct drm_mode_config</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="Linux GPU Driver Developer's Guide"><link rel="up" href="drm-kms-init.html#id-1.3.4.8.10" title="KMS Data Structures"><link rel="prev" href="API-struct-drm-mode-config-funcs.html" title="struct drm_mode_config_funcs"><link rel="next" href="API-drm-for-each-plane-mask.html" title="drm_for_each_plane_mask"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">struct drm_mode_config</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-struct-drm-mode-config-funcs.html">Prev</a> </td><th width="60%" align="center">KMS Data Structures</th><td width="20%" align="right"> <a accesskey="n" href="API-drm-for-each-plane-mask.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-struct-drm-mode-config"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>struct drm_mode_config — 
2     Mode configuration control structure
3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="programlisting">
4struct drm_mode_config {
5  struct mutex mutex;
6  struct drm_modeset_lock connection_mutex;
7  struct drm_modeset_acquire_ctx * acquire_ctx;
8  struct mutex idr_mutex;
9  struct idr crtc_idr;
10  struct mutex fb_lock;
11  int num_fb;
12  struct list_head fb_list;
13  int num_connector;
14  struct list_head connector_list;
15  int num_encoder;
16  struct list_head encoder_list;
17  int num_overlay_plane;
18  int num_total_plane;
19  struct list_head plane_list;
20  int num_crtc;
21  struct list_head crtc_list;
22  struct list_head property_list;
23  int min_width;
24  int min_height;
25  int max_width;
26  int max_height;
27  const struct drm_mode_config_funcs * funcs;
28  resource_size_t fb_base;
29  bool poll_enabled;
30  bool poll_running;
31  struct delayed_work output_poll_work;
32  struct mutex blob_lock;
33  struct list_head property_blob_list;
34  uint32_t preferred_depth;
35  uint32_t prefer_shadow;
36  bool async_page_flip;
37  uint32_t cursor_width;
38  uint32_t cursor_height;
39};  </pre></div><div class="refsect1"><a name="id-1.3.4.8.10.18.5"></a><h2>Members</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term">mutex</span></dt><dd><p>
40   mutex protecting KMS related lists and structures
41      </p></dd><dt><span class="term">connection_mutex</span></dt><dd><p>
42   ww mutex protecting connector state and routing
43      </p></dd><dt><span class="term">acquire_ctx</span></dt><dd><p>
44   global implicit acquire context used by atomic drivers for
45   legacy ioctls
46      </p></dd><dt><span class="term">idr_mutex</span></dt><dd><p>
47   mutex for KMS ID allocation and management
48      </p></dd><dt><span class="term">crtc_idr</span></dt><dd><p>
49   main KMS ID tracking object
50      </p></dd><dt><span class="term">fb_lock</span></dt><dd><p>
51   mutex to protect fb state and lists
52      </p></dd><dt><span class="term">num_fb</span></dt><dd><p>
53   number of fbs available
54      </p></dd><dt><span class="term">fb_list</span></dt><dd><p>
55   list of framebuffers available
56      </p></dd><dt><span class="term">num_connector</span></dt><dd><p>
57   number of connectors on this device
58      </p></dd><dt><span class="term">connector_list</span></dt><dd><p>
59   list of connector objects
60      </p></dd><dt><span class="term">num_encoder</span></dt><dd><p>
61   number of encoders on this device
62      </p></dd><dt><span class="term">encoder_list</span></dt><dd><p>
63   list of encoder objects
64      </p></dd><dt><span class="term">num_overlay_plane</span></dt><dd><p>
65   number of overlay planes on this device
66      </p></dd><dt><span class="term">num_total_plane</span></dt><dd><p>
67   number of universal (i.e. with primary/curso) planes on this device
68      </p></dd><dt><span class="term">plane_list</span></dt><dd><p>
69   list of plane objects
70      </p></dd><dt><span class="term">num_crtc</span></dt><dd><p>
71   number of CRTCs on this device
72      </p></dd><dt><span class="term">crtc_list</span></dt><dd><p>
73   list of CRTC objects
74      </p></dd><dt><span class="term">property_list</span></dt><dd><p>
75   list of property objects
76      </p></dd><dt><span class="term">min_width</span></dt><dd><p>
77   minimum pixel width on this device
78      </p></dd><dt><span class="term">min_height</span></dt><dd><p>
79   minimum pixel height on this device
80      </p></dd><dt><span class="term">max_width</span></dt><dd><p>
81   maximum pixel width on this device
82      </p></dd><dt><span class="term">max_height</span></dt><dd><p>
83   maximum pixel height on this device
84      </p></dd><dt><span class="term">funcs</span></dt><dd><p>
85   core driver provided mode setting functions
86      </p></dd><dt><span class="term">fb_base</span></dt><dd><p>
87   base address of the framebuffer
88      </p></dd><dt><span class="term">poll_enabled</span></dt><dd><p>
89   track polling support for this device
90      </p></dd><dt><span class="term">poll_running</span></dt><dd><p>
91   track polling status for this device
92      </p></dd><dt><span class="term">output_poll_work</span></dt><dd><p>
93   delayed work for polling in process context
94      </p></dd><dt><span class="term">blob_lock</span></dt><dd><p>
95   mutex for blob property allocation and management
96      </p></dd><dt><span class="term">property_blob_list</span></dt><dd><p>
97   list of all the blob property objects
98      </p></dd><dt><span class="term">preferred_depth</span></dt><dd><p>
99   preferred RBG pixel depth, used by fb helpers
100      </p></dd><dt><span class="term">prefer_shadow</span></dt><dd><p>
101   hint to userspace to prefer shadow-fb rendering
102      </p></dd><dt><span class="term">async_page_flip</span></dt><dd><p>
103   does this device support async flips on the primary plane?
104      </p></dd><dt><span class="term">cursor_width</span></dt><dd><p>
105   hint to userspace for max cursor width
106      </p></dd><dt><span class="term">cursor_height</span></dt><dd><p>
107   hint to userspace for max cursor height
108      </p></dd></dl></div></div><div class="refsect1"><a name="id-1.3.4.8.10.18.6"></a><h2>_property</h2><p>
109   core property tracking
110</p></div><div class="refsect1"><a name="id-1.3.4.8.10.18.7"></a><h2>Description</h2><p>
111   Core mode resource tracking structure.  All CRTC, encoders, and connectors
112   enumerated by the driver are added here, as are global properties.  Some
113   global restrictions are also here, e.g. dimension restrictions.
114</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-struct-drm-mode-config-funcs.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="drm-kms-init.html#id-1.3.4.8.10">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-drm-for-each-plane-mask.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">struct drm_mode_config_funcs</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">drm_for_each_plane_mask</span></td></tr></table></div></body></html>
115