blob: 240a8ae9c81c043cb1b2383a19522aa99e4b527b [file] [log] [blame]
Ben Cheng655a7c02013-10-16 16:09:24 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef _DRM_MODE_H
20#define _DRM_MODE_H
21#include <linux/types.h>
22#define DRM_DISPLAY_INFO_LEN 32
23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24#define DRM_CONNECTOR_NAME_LEN 32
25#define DRM_DISPLAY_MODE_LEN 32
26#define DRM_PROP_NAME_LEN 32
Tao Baod7db5942015-01-28 10:07:51 -080027#define DRM_MODE_TYPE_BUILTIN (1 << 0)
Ben Cheng655a7c02013-10-16 16:09:24 -070028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080029#define DRM_MODE_TYPE_CLOCK_C ((1 << 1) | DRM_MODE_TYPE_BUILTIN)
30#define DRM_MODE_TYPE_CRTC_C ((1 << 2) | DRM_MODE_TYPE_BUILTIN)
31#define DRM_MODE_TYPE_PREFERRED (1 << 3)
32#define DRM_MODE_TYPE_DEFAULT (1 << 4)
Ben Cheng655a7c02013-10-16 16:09:24 -070033/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080034#define DRM_MODE_TYPE_USERDEF (1 << 5)
35#define DRM_MODE_TYPE_DRIVER (1 << 6)
36#define DRM_MODE_FLAG_PHSYNC (1 << 0)
37#define DRM_MODE_FLAG_NHSYNC (1 << 1)
Ben Cheng655a7c02013-10-16 16:09:24 -070038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080039#define DRM_MODE_FLAG_PVSYNC (1 << 2)
40#define DRM_MODE_FLAG_NVSYNC (1 << 3)
41#define DRM_MODE_FLAG_INTERLACE (1 << 4)
42#define DRM_MODE_FLAG_DBLSCAN (1 << 5)
Ben Cheng655a7c02013-10-16 16:09:24 -070043/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080044#define DRM_MODE_FLAG_CSYNC (1 << 6)
45#define DRM_MODE_FLAG_PCSYNC (1 << 7)
46#define DRM_MODE_FLAG_NCSYNC (1 << 8)
47#define DRM_MODE_FLAG_HSKEW (1 << 9)
Ben Cheng655a7c02013-10-16 16:09:24 -070048/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080049#define DRM_MODE_FLAG_BCAST (1 << 10)
50#define DRM_MODE_FLAG_PIXMUX (1 << 11)
51#define DRM_MODE_FLAG_DBLCLK (1 << 12)
52#define DRM_MODE_FLAG_CLKDIV2 (1 << 13)
Ben Cheng655a7c02013-10-16 16:09:24 -070053/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080054#define DRM_MODE_FLAG_3D_MASK (0x1f << 14)
55#define DRM_MODE_FLAG_3D_NONE (0 << 14)
56#define DRM_MODE_FLAG_3D_FRAME_PACKING (1 << 14)
57#define DRM_MODE_FLAG_3D_FIELD_ALTERNATIVE (2 << 14)
Christopher Ferris38062f92014-07-09 15:33:25 -070058/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080059#define DRM_MODE_FLAG_3D_LINE_ALTERNATIVE (3 << 14)
60#define DRM_MODE_FLAG_3D_SIDE_BY_SIDE_FULL (4 << 14)
61#define DRM_MODE_FLAG_3D_L_DEPTH (5 << 14)
62#define DRM_MODE_FLAG_3D_L_DEPTH_GFX_GFX_DEPTH (6 << 14)
Christopher Ferris38062f92014-07-09 15:33:25 -070063/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080064#define DRM_MODE_FLAG_3D_TOP_AND_BOTTOM (7 << 14)
65#define DRM_MODE_FLAG_3D_SIDE_BY_SIDE_HALF (8 << 14)
Ben Cheng655a7c02013-10-16 16:09:24 -070066#define DRM_MODE_DPMS_ON 0
67#define DRM_MODE_DPMS_STANDBY 1
Christopher Ferris38062f92014-07-09 15:33:25 -070068/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -070069#define DRM_MODE_DPMS_SUSPEND 2
70#define DRM_MODE_DPMS_OFF 3
Ben Cheng655a7c02013-10-16 16:09:24 -070071#define DRM_MODE_SCALE_NONE 0
72#define DRM_MODE_SCALE_FULLSCREEN 1
Christopher Ferris38062f92014-07-09 15:33:25 -070073/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -070074#define DRM_MODE_SCALE_CENTER 2
75#define DRM_MODE_SCALE_ASPECT 3
Christopher Ferris82d75042015-01-26 10:57:07 -080076#define DRM_MODE_PICTURE_ASPECT_NONE 0
77#define DRM_MODE_PICTURE_ASPECT_4_3 1
78/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79#define DRM_MODE_PICTURE_ASPECT_16_9 2
Ben Cheng655a7c02013-10-16 16:09:24 -070080#define DRM_MODE_DITHERING_OFF 0
81#define DRM_MODE_DITHERING_ON 1
82#define DRM_MODE_DITHERING_AUTO 2
Christopher Ferris82d75042015-01-26 10:57:07 -080083/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -070084#define DRM_MODE_DIRTY_OFF 0
Ben Cheng655a7c02013-10-16 16:09:24 -070085#define DRM_MODE_DIRTY_ON 1
86#define DRM_MODE_DIRTY_ANNOTATE 2
87struct drm_mode_modeinfo {
Christopher Ferris82d75042015-01-26 10:57:07 -080088/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080089 __u32 clock;
Christopher Ferris05d08e92016-02-04 13:16:38 -080090 __u16 hdisplay;
91 __u16 hsync_start;
92 __u16 hsync_end;
93/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
94 __u16 htotal;
95 __u16 hskew;
96 __u16 vdisplay;
97 __u16 vsync_start;
98/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
99 __u16 vsync_end;
100 __u16 vtotal;
101 __u16 vscan;
Tao Baod7db5942015-01-28 10:07:51 -0800102 __u32 vrefresh;
Christopher Ferris82d75042015-01-26 10:57:07 -0800103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800104 __u32 flags;
105 __u32 type;
106 char name[DRM_DISPLAY_MODE_LEN];
Ben Cheng655a7c02013-10-16 16:09:24 -0700107};
Christopher Ferris82d75042015-01-26 10:57:07 -0800108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700109struct drm_mode_card_res {
Tao Baod7db5942015-01-28 10:07:51 -0800110 __u64 fb_id_ptr;
111 __u64 crtc_id_ptr;
112 __u64 connector_id_ptr;
Christopher Ferris82d75042015-01-26 10:57:07 -0800113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800114 __u64 encoder_id_ptr;
115 __u32 count_fbs;
116 __u32 count_crtcs;
117 __u32 count_connectors;
Christopher Ferris82d75042015-01-26 10:57:07 -0800118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800119 __u32 count_encoders;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800120 __u32 min_width;
121 __u32 max_width;
122 __u32 min_height;
Christopher Ferris82d75042015-01-26 10:57:07 -0800123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800124 __u32 max_height;
125};
Ben Cheng655a7c02013-10-16 16:09:24 -0700126struct drm_mode_crtc {
Tao Baod7db5942015-01-28 10:07:51 -0800127 __u64 set_connectors_ptr;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800129 __u32 count_connectors;
130 __u32 crtc_id;
Tao Baod7db5942015-01-28 10:07:51 -0800131 __u32 fb_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800132 __u32 x;
133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
134 __u32 y;
Tao Baod7db5942015-01-28 10:07:51 -0800135 __u32 gamma_size;
136 __u32 mode_valid;
Tao Baod7db5942015-01-28 10:07:51 -0800137 struct drm_mode_modeinfo mode;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700139};
Tao Baod7db5942015-01-28 10:07:51 -0800140#define DRM_MODE_PRESENT_TOP_FIELD (1 << 0)
141#define DRM_MODE_PRESENT_BOTTOM_FIELD (1 << 1)
Ben Cheng655a7c02013-10-16 16:09:24 -0700142struct drm_mode_set_plane {
Christopher Ferris05d08e92016-02-04 13:16:38 -0800143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800144 __u32 plane_id;
145 __u32 crtc_id;
146 __u32 fb_id;
Tao Baod7db5942015-01-28 10:07:51 -0800147 __u32 flags;
Christopher Ferris82d75042015-01-26 10:57:07 -0800148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800149 __s32 crtc_x;
150 __s32 crtc_y;
151 __u32 crtc_w;
152 __u32 crtc_h;
153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
154 __u32 src_x;
155 __u32 src_y;
156 __u32 src_h;
157 __u32 src_w;
158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700159};
160struct drm_mode_get_plane {
Tao Baod7db5942015-01-28 10:07:51 -0800161 __u32 plane_id;
Tao Baod7db5942015-01-28 10:07:51 -0800162 __u32 crtc_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800164 __u32 fb_id;
165 __u32 possible_crtcs;
166 __u32 gamma_size;
Tao Baod7db5942015-01-28 10:07:51 -0800167 __u32 count_format_types;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800169 __u64 format_type_ptr;
Ben Cheng655a7c02013-10-16 16:09:24 -0700170};
171struct drm_mode_get_plane_res {
Tao Baod7db5942015-01-28 10:07:51 -0800172 __u64 plane_id_ptr;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800174 __u32 count_planes;
Ben Cheng655a7c02013-10-16 16:09:24 -0700175};
176#define DRM_MODE_ENCODER_NONE 0
177#define DRM_MODE_ENCODER_DAC 1
Christopher Ferris05d08e92016-02-04 13:16:38 -0800178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700179#define DRM_MODE_ENCODER_TMDS 2
180#define DRM_MODE_ENCODER_LVDS 3
181#define DRM_MODE_ENCODER_TVDAC 4
182#define DRM_MODE_ENCODER_VIRTUAL 5
Christopher Ferris05d08e92016-02-04 13:16:38 -0800183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris38062f92014-07-09 15:33:25 -0700184#define DRM_MODE_ENCODER_DSI 6
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700185#define DRM_MODE_ENCODER_DPMST 7
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700186struct drm_mode_get_encoder {
Tao Baod7db5942015-01-28 10:07:51 -0800187 __u32 encoder_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800189 __u32 encoder_type;
190 __u32 crtc_id;
191 __u32 possible_crtcs;
Tao Baod7db5942015-01-28 10:07:51 -0800192 __u32 possible_clones;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700194};
195#define DRM_MODE_SUBCONNECTOR_Automatic 0
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700196#define DRM_MODE_SUBCONNECTOR_Unknown 0
Ben Cheng655a7c02013-10-16 16:09:24 -0700197#define DRM_MODE_SUBCONNECTOR_DVID 3
Christopher Ferris05d08e92016-02-04 13:16:38 -0800198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700199#define DRM_MODE_SUBCONNECTOR_DVIA 4
200#define DRM_MODE_SUBCONNECTOR_Composite 5
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700201#define DRM_MODE_SUBCONNECTOR_SVIDEO 6
Ben Cheng655a7c02013-10-16 16:09:24 -0700202#define DRM_MODE_SUBCONNECTOR_Component 8
Christopher Ferris05d08e92016-02-04 13:16:38 -0800203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700204#define DRM_MODE_SUBCONNECTOR_SCART 9
205#define DRM_MODE_CONNECTOR_Unknown 0
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700206#define DRM_MODE_CONNECTOR_VGA 1
Ben Cheng655a7c02013-10-16 16:09:24 -0700207#define DRM_MODE_CONNECTOR_DVII 2
Christopher Ferris05d08e92016-02-04 13:16:38 -0800208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700209#define DRM_MODE_CONNECTOR_DVID 3
210#define DRM_MODE_CONNECTOR_DVIA 4
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700211#define DRM_MODE_CONNECTOR_Composite 5
Ben Cheng655a7c02013-10-16 16:09:24 -0700212#define DRM_MODE_CONNECTOR_SVIDEO 6
Christopher Ferris05d08e92016-02-04 13:16:38 -0800213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700214#define DRM_MODE_CONNECTOR_LVDS 7
215#define DRM_MODE_CONNECTOR_Component 8
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700216#define DRM_MODE_CONNECTOR_9PinDIN 9
Ben Cheng655a7c02013-10-16 16:09:24 -0700217#define DRM_MODE_CONNECTOR_DisplayPort 10
Christopher Ferris05d08e92016-02-04 13:16:38 -0800218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700219#define DRM_MODE_CONNECTOR_HDMIA 11
220#define DRM_MODE_CONNECTOR_HDMIB 12
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700221#define DRM_MODE_CONNECTOR_TV 13
Ben Cheng655a7c02013-10-16 16:09:24 -0700222#define DRM_MODE_CONNECTOR_eDP 14
Christopher Ferris05d08e92016-02-04 13:16:38 -0800223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700224#define DRM_MODE_CONNECTOR_VIRTUAL 15
Christopher Ferris38062f92014-07-09 15:33:25 -0700225#define DRM_MODE_CONNECTOR_DSI 16
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700226struct drm_mode_get_connector {
Tao Baod7db5942015-01-28 10:07:51 -0800227 __u64 encoders_ptr;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800228/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800229 __u64 modes_ptr;
230 __u64 props_ptr;
231 __u64 prop_values_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800232 __u32 count_modes;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800233/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800234 __u32 count_props;
235 __u32 count_encoders;
236 __u32 encoder_id;
Tao Baod7db5942015-01-28 10:07:51 -0800237 __u32 connector_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800238/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800239 __u32 connector_type;
240 __u32 connector_type_id;
241 __u32 connection;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800242 __u32 mm_width;
Christopher Ferris82d75042015-01-26 10:57:07 -0800243/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800244 __u32 mm_height;
Tao Baod7db5942015-01-28 10:07:51 -0800245 __u32 subpixel;
246 __u32 pad;
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700247};
Christopher Ferris82d75042015-01-26 10:57:07 -0800248/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800249#define DRM_MODE_PROP_PENDING (1 << 0)
250#define DRM_MODE_PROP_RANGE (1 << 1)
251#define DRM_MODE_PROP_IMMUTABLE (1 << 2)
252#define DRM_MODE_PROP_ENUM (1 << 3)
Christopher Ferris82d75042015-01-26 10:57:07 -0800253/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800254#define DRM_MODE_PROP_BLOB (1 << 4)
255#define DRM_MODE_PROP_BITMASK (1 << 5)
256#define DRM_MODE_PROP_LEGACY_TYPE (DRM_MODE_PROP_RANGE | DRM_MODE_PROP_ENUM | DRM_MODE_PROP_BLOB | DRM_MODE_PROP_BITMASK)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700257#define DRM_MODE_PROP_EXTENDED_TYPE 0x0000ffc0
Christopher Ferris82d75042015-01-26 10:57:07 -0800258/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700259#define DRM_MODE_PROP_TYPE(n) ((n) << 6)
260#define DRM_MODE_PROP_OBJECT DRM_MODE_PROP_TYPE(1)
261#define DRM_MODE_PROP_SIGNED_RANGE DRM_MODE_PROP_TYPE(2)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800262#define DRM_MODE_PROP_ATOMIC 0x80000000
Christopher Ferris82d75042015-01-26 10:57:07 -0800263/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800264struct drm_mode_property_enum {
Tao Baod7db5942015-01-28 10:07:51 -0800265 __u64 value;
266 char name[DRM_PROP_NAME_LEN];
Ben Cheng655a7c02013-10-16 16:09:24 -0700267};
Christopher Ferris82d75042015-01-26 10:57:07 -0800268/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800269struct drm_mode_get_property {
Tao Baod7db5942015-01-28 10:07:51 -0800270 __u64 values_ptr;
271 __u64 enum_blob_ptr;
272 __u32 prop_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800273/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800274 __u32 flags;
Tao Baod7db5942015-01-28 10:07:51 -0800275 char name[DRM_PROP_NAME_LEN];
276 __u32 count_values;
277 __u32 count_enum_blobs;
Christopher Ferris82d75042015-01-26 10:57:07 -0800278/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800279};
Ben Cheng655a7c02013-10-16 16:09:24 -0700280struct drm_mode_connector_set_property {
Tao Baod7db5942015-01-28 10:07:51 -0800281 __u64 value;
282 __u32 prop_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800283/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800284 __u32 connector_id;
Ben Cheng655a7c02013-10-16 16:09:24 -0700285};
Christopher Ferris38062f92014-07-09 15:33:25 -0700286struct drm_mode_obj_get_properties {
Tao Baod7db5942015-01-28 10:07:51 -0800287 __u64 props_ptr;
Christopher Ferris82d75042015-01-26 10:57:07 -0800288/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800289 __u64 prop_values_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800290 __u32 count_props;
291 __u32 obj_id;
292 __u32 obj_type;
Christopher Ferris82d75042015-01-26 10:57:07 -0800293/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800294};
Ben Cheng655a7c02013-10-16 16:09:24 -0700295struct drm_mode_obj_set_property {
Tao Baod7db5942015-01-28 10:07:51 -0800296 __u64 value;
297 __u32 prop_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800298/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800299 __u32 obj_id;
Tao Baod7db5942015-01-28 10:07:51 -0800300 __u32 obj_type;
Christopher Ferris38062f92014-07-09 15:33:25 -0700301};
Ben Cheng655a7c02013-10-16 16:09:24 -0700302struct drm_mode_get_blob {
Christopher Ferris82d75042015-01-26 10:57:07 -0800303/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800304 __u32 blob_id;
Tao Baod7db5942015-01-28 10:07:51 -0800305 __u32 length;
306 __u64 data;
Ben Cheng655a7c02013-10-16 16:09:24 -0700307};
Christopher Ferris82d75042015-01-26 10:57:07 -0800308/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800309struct drm_mode_fb_cmd {
Tao Baod7db5942015-01-28 10:07:51 -0800310 __u32 fb_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800311 __u32 width;
312 __u32 height;
313/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800314 __u32 pitch;
315 __u32 bpp;
Tao Baod7db5942015-01-28 10:07:51 -0800316 __u32 depth;
317 __u32 handle;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800318/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700319};
Tao Baod7db5942015-01-28 10:07:51 -0800320#define DRM_MODE_FB_INTERLACED (1 << 0)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800321#define DRM_MODE_FB_MODIFIERS (1 << 1)
Ben Cheng655a7c02013-10-16 16:09:24 -0700322struct drm_mode_fb_cmd2 {
Christopher Ferris05d08e92016-02-04 13:16:38 -0800323/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800324 __u32 fb_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800325 __u32 width;
326 __u32 height;
Tao Baod7db5942015-01-28 10:07:51 -0800327 __u32 pixel_format;
Christopher Ferris82d75042015-01-26 10:57:07 -0800328/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800329 __u32 flags;
330 __u32 handles[4];
331 __u32 pitches[4];
332 __u32 offsets[4];
Christopher Ferris82d75042015-01-26 10:57:07 -0800333/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800334 __u64 modifier[4];
Ben Cheng655a7c02013-10-16 16:09:24 -0700335};
Christopher Ferris38062f92014-07-09 15:33:25 -0700336#define DRM_MODE_FB_DIRTY_ANNOTATE_COPY 0x01
Ben Cheng655a7c02013-10-16 16:09:24 -0700337#define DRM_MODE_FB_DIRTY_ANNOTATE_FILL 0x02
Christopher Ferris82d75042015-01-26 10:57:07 -0800338/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800339#define DRM_MODE_FB_DIRTY_FLAGS 0x03
Ben Cheng655a7c02013-10-16 16:09:24 -0700340#define DRM_MODE_FB_DIRTY_MAX_CLIPS 256
Christopher Ferris38062f92014-07-09 15:33:25 -0700341struct drm_mode_fb_dirty_cmd {
Tao Baod7db5942015-01-28 10:07:51 -0800342 __u32 fb_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800343/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800344 __u32 flags;
Tao Baod7db5942015-01-28 10:07:51 -0800345 __u32 color;
346 __u32 num_clips;
347 __u64 clips_ptr;
Christopher Ferris82d75042015-01-26 10:57:07 -0800348/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800349};
Ben Cheng655a7c02013-10-16 16:09:24 -0700350struct drm_mode_mode_cmd {
Tao Baod7db5942015-01-28 10:07:51 -0800351 __u32 connector_id;
352 struct drm_mode_modeinfo mode;
Christopher Ferris82d75042015-01-26 10:57:07 -0800353/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800354};
Ben Cheng655a7c02013-10-16 16:09:24 -0700355#define DRM_MODE_CURSOR_BO 0x01
Christopher Ferris38062f92014-07-09 15:33:25 -0700356#define DRM_MODE_CURSOR_MOVE 0x02
Ben Cheng655a7c02013-10-16 16:09:24 -0700357#define DRM_MODE_CURSOR_FLAGS 0x03
Christopher Ferris82d75042015-01-26 10:57:07 -0800358/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800359struct drm_mode_cursor {
Tao Baod7db5942015-01-28 10:07:51 -0800360 __u32 flags;
361 __u32 crtc_id;
362 __s32 x;
Christopher Ferris82d75042015-01-26 10:57:07 -0800363/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800364 __s32 y;
Tao Baod7db5942015-01-28 10:07:51 -0800365 __u32 width;
366 __u32 height;
367 __u32 handle;
Christopher Ferris82d75042015-01-26 10:57:07 -0800368/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800369};
Christopher Ferris38062f92014-07-09 15:33:25 -0700370struct drm_mode_cursor2 {
Tao Baod7db5942015-01-28 10:07:51 -0800371 __u32 flags;
372 __u32 crtc_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800373/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800374 __s32 x;
Tao Baod7db5942015-01-28 10:07:51 -0800375 __s32 y;
376 __u32 width;
377 __u32 height;
Christopher Ferris82d75042015-01-26 10:57:07 -0800378/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800379 __u32 handle;
Tao Baod7db5942015-01-28 10:07:51 -0800380 __s32 hot_x;
381 __s32 hot_y;
Christopher Ferris38062f92014-07-09 15:33:25 -0700382};
Christopher Ferris82d75042015-01-26 10:57:07 -0800383/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800384struct drm_mode_crtc_lut {
Tao Baod7db5942015-01-28 10:07:51 -0800385 __u32 crtc_id;
386 __u32 gamma_size;
387 __u64 red;
Christopher Ferris82d75042015-01-26 10:57:07 -0800388/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800389 __u64 green;
Tao Baod7db5942015-01-28 10:07:51 -0800390 __u64 blue;
Elliott Hughes8cb52b02013-11-21 13:43:23 -0800391};
Ben Cheng655a7c02013-10-16 16:09:24 -0700392#define DRM_MODE_PAGE_FLIP_EVENT 0x01
Christopher Ferris82d75042015-01-26 10:57:07 -0800393/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800394#define DRM_MODE_PAGE_FLIP_ASYNC 0x02
Tao Baod7db5942015-01-28 10:07:51 -0800395#define DRM_MODE_PAGE_FLIP_FLAGS (DRM_MODE_PAGE_FLIP_EVENT | DRM_MODE_PAGE_FLIP_ASYNC)
Christopher Ferris38062f92014-07-09 15:33:25 -0700396struct drm_mode_crtc_page_flip {
Tao Baod7db5942015-01-28 10:07:51 -0800397 __u32 crtc_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800398/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800399 __u32 fb_id;
Tao Baod7db5942015-01-28 10:07:51 -0800400 __u32 flags;
401 __u32 reserved;
402 __u64 user_data;
Christopher Ferris82d75042015-01-26 10:57:07 -0800403/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800404};
Ben Cheng655a7c02013-10-16 16:09:24 -0700405struct drm_mode_create_dumb {
Tao Baod7db5942015-01-28 10:07:51 -0800406 uint32_t height;
407 uint32_t width;
Christopher Ferris82d75042015-01-26 10:57:07 -0800408/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800409 uint32_t bpp;
Tao Baod7db5942015-01-28 10:07:51 -0800410 uint32_t flags;
411 uint32_t handle;
412 uint32_t pitch;
Christopher Ferris82d75042015-01-26 10:57:07 -0800413/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800414 uint64_t size;
Ben Cheng655a7c02013-10-16 16:09:24 -0700415};
Christopher Ferris38062f92014-07-09 15:33:25 -0700416struct drm_mode_map_dumb {
Tao Baod7db5942015-01-28 10:07:51 -0800417 __u32 handle;
Christopher Ferris82d75042015-01-26 10:57:07 -0800418/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris05d08e92016-02-04 13:16:38 -0800419 __u32 pad;
Tao Baod7db5942015-01-28 10:07:51 -0800420 __u64 offset;
Christopher Ferris38062f92014-07-09 15:33:25 -0700421};
Elliott Hughes8cb52b02013-11-21 13:43:23 -0800422struct drm_mode_destroy_dumb {
Christopher Ferris05d08e92016-02-04 13:16:38 -0800423/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800424 uint32_t handle;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800425};
426#define DRM_MODE_ATOMIC_TEST_ONLY 0x0100
427#define DRM_MODE_ATOMIC_NONBLOCK 0x0200
428/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
429#define DRM_MODE_ATOMIC_ALLOW_MODESET 0x0400
430#define DRM_MODE_ATOMIC_FLAGS (DRM_MODE_PAGE_FLIP_EVENT | DRM_MODE_PAGE_FLIP_ASYNC | DRM_MODE_ATOMIC_TEST_ONLY | DRM_MODE_ATOMIC_NONBLOCK | DRM_MODE_ATOMIC_ALLOW_MODESET)
431struct drm_mode_atomic {
432 __u32 flags;
433/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
434 __u32 count_objs;
435 __u64 objs_ptr;
436 __u64 count_props_ptr;
437 __u64 props_ptr;
438/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
439 __u64 prop_values_ptr;
440 __u64 reserved;
441 __u64 user_data;
442};
443/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
444struct drm_mode_create_blob {
445 __u64 data;
446 __u32 length;
447 __u32 blob_id;
Christopher Ferris82d75042015-01-26 10:57:07 -0800448/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700449};
Christopher Ferris05d08e92016-02-04 13:16:38 -0800450struct drm_mode_destroy_blob {
451 __u32 blob_id;
452};
453/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris38062f92014-07-09 15:33:25 -0700454#endif