blob: 94b96364ff1752219910155c0c4ecc5475db8073 [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 _UAPI_I915_DRM_H_
20#define _UAPI_I915_DRM_H_
Christopher Ferris106b3a82016-08-24 12:15:38 -070021#include "drm.h"
22#ifdef __cplusplus
Ben Cheng655a7c02013-10-16 16:09:24 -070023/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris106b3a82016-08-24 12:15:38 -070024#endif
25#define I915_L3_PARITY_UEVENT "L3_PARITY_ERROR"
Christopher Ferris38062f92014-07-09 15:33:25 -070026#define I915_ERROR_UEVENT "ERROR"
27#define I915_RESET_UEVENT "RESET"
Christopher Ferris106b3a82016-08-24 12:15:38 -070028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080029enum i915_mocs_table_index {
30 I915_MOCS_UNCACHED,
31 I915_MOCS_PTE,
32 I915_MOCS_CACHED,
33/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34};
Christopher Ferris38062f92014-07-09 15:33:25 -070035#define I915_NR_TEX_REGIONS 255
Ben Cheng655a7c02013-10-16 16:09:24 -070036#define I915_LOG_MIN_TEX_REGION_SIZE 14
37typedef struct _drm_i915_init {
Christopher Ferris106b3a82016-08-24 12:15:38 -070038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080039 enum {
Tao Baod7db5942015-01-28 10:07:51 -080040 I915_INIT_DMA = 0x01,
41 I915_CLEANUP_DMA = 0x02,
Tao Baod7db5942015-01-28 10:07:51 -080042 I915_RESUME_DMA = 0x03
Christopher Ferris106b3a82016-08-24 12:15:38 -070043/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080044 } func;
Tao Baod7db5942015-01-28 10:07:51 -080045 unsigned int mmio_offset;
46 int sarea_priv_offset;
Tao Baod7db5942015-01-28 10:07:51 -080047 unsigned int ring_start;
Christopher Ferris106b3a82016-08-24 12:15:38 -070048/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080049 unsigned int ring_end;
Tao Baod7db5942015-01-28 10:07:51 -080050 unsigned int ring_size;
51 unsigned int front_offset;
Tao Baod7db5942015-01-28 10:07:51 -080052 unsigned int back_offset;
Christopher Ferris106b3a82016-08-24 12:15:38 -070053/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080054 unsigned int depth_offset;
Tao Baod7db5942015-01-28 10:07:51 -080055 unsigned int w;
56 unsigned int h;
Tao Baod7db5942015-01-28 10:07:51 -080057 unsigned int pitch;
Christopher Ferris106b3a82016-08-24 12:15:38 -070058/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080059 unsigned int pitch_bits;
Tao Baod7db5942015-01-28 10:07:51 -080060 unsigned int back_pitch;
61 unsigned int depth_pitch;
Tao Baod7db5942015-01-28 10:07:51 -080062 unsigned int cpp;
Christopher Ferris106b3a82016-08-24 12:15:38 -070063/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080064 unsigned int chipset;
Ben Cheng655a7c02013-10-16 16:09:24 -070065} drm_i915_init_t;
Ben Cheng655a7c02013-10-16 16:09:24 -070066typedef struct _drm_i915_sarea {
Tao Baod7db5942015-01-28 10:07:51 -080067 struct drm_tex_region texList[I915_NR_TEX_REGIONS + 1];
Christopher Ferris106b3a82016-08-24 12:15:38 -070068/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080069 int last_upload;
Tao Baod7db5942015-01-28 10:07:51 -080070 int last_enqueue;
71 int last_dispatch;
Tao Baod7db5942015-01-28 10:07:51 -080072 int ctxOwner;
Christopher Ferris106b3a82016-08-24 12:15:38 -070073/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080074 int texAge;
Tao Baod7db5942015-01-28 10:07:51 -080075 int pf_enabled;
76 int pf_active;
Tao Baod7db5942015-01-28 10:07:51 -080077 int pf_current_page;
Christopher Ferris106b3a82016-08-24 12:15:38 -070078/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080079 int perf_boxes;
Tao Baod7db5942015-01-28 10:07:51 -080080 int width, height;
81 drm_handle_t front_handle;
Tao Baod7db5942015-01-28 10:07:51 -080082 int front_offset;
Christopher Ferris106b3a82016-08-24 12:15:38 -070083/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080084 int front_size;
Tao Baod7db5942015-01-28 10:07:51 -080085 drm_handle_t back_handle;
86 int back_offset;
Tao Baod7db5942015-01-28 10:07:51 -080087 int back_size;
Christopher Ferris106b3a82016-08-24 12:15:38 -070088/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080089 drm_handle_t depth_handle;
Tao Baod7db5942015-01-28 10:07:51 -080090 int depth_offset;
91 int depth_size;
Tao Baod7db5942015-01-28 10:07:51 -080092 drm_handle_t tex_handle;
Christopher Ferris106b3a82016-08-24 12:15:38 -070093/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080094 int tex_offset;
Tao Baod7db5942015-01-28 10:07:51 -080095 int tex_size;
96 int log_tex_granularity;
Tao Baod7db5942015-01-28 10:07:51 -080097 int pitch;
Christopher Ferris106b3a82016-08-24 12:15:38 -070098/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -080099 int rotation;
Tao Baod7db5942015-01-28 10:07:51 -0800100 int rotated_offset;
101 int rotated_size;
Tao Baod7db5942015-01-28 10:07:51 -0800102 int rotated_pitch;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800104 int virtualX, virtualY;
Tao Baod7db5942015-01-28 10:07:51 -0800105 unsigned int front_tiled;
106 unsigned int back_tiled;
Tao Baod7db5942015-01-28 10:07:51 -0800107 unsigned int depth_tiled;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800109 unsigned int rotated_tiled;
Tao Baod7db5942015-01-28 10:07:51 -0800110 unsigned int rotated2_tiled;
111 int pipeA_x;
Tao Baod7db5942015-01-28 10:07:51 -0800112 int pipeA_y;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800114 int pipeA_w;
Tao Baod7db5942015-01-28 10:07:51 -0800115 int pipeA_h;
116 int pipeB_x;
Tao Baod7db5942015-01-28 10:07:51 -0800117 int pipeB_y;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800119 int pipeB_w;
Tao Baod7db5942015-01-28 10:07:51 -0800120 int pipeB_h;
121 drm_handle_t unused_handle;
Tao Baod7db5942015-01-28 10:07:51 -0800122 __u32 unused1, unused2, unused3;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800124 __u32 front_bo_handle;
Tao Baod7db5942015-01-28 10:07:51 -0800125 __u32 back_bo_handle;
126 __u32 unused_bo_handle;
Tao Baod7db5942015-01-28 10:07:51 -0800127 __u32 depth_bo_handle;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800129} drm_i915_sarea_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700130#define planeA_x pipeA_x
Ben Cheng655a7c02013-10-16 16:09:24 -0700131#define planeA_y pipeA_y
132#define planeA_w pipeA_w
Christopher Ferris106b3a82016-08-24 12:15:38 -0700133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800134#define planeA_h pipeA_h
Ben Cheng655a7c02013-10-16 16:09:24 -0700135#define planeB_x pipeB_x
Ben Cheng655a7c02013-10-16 16:09:24 -0700136#define planeB_y pipeB_y
137#define planeB_w pipeB_w
Christopher Ferris106b3a82016-08-24 12:15:38 -0700138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800139#define planeB_h pipeB_h
Ben Cheng655a7c02013-10-16 16:09:24 -0700140#define I915_BOX_RING_EMPTY 0x1
Ben Cheng655a7c02013-10-16 16:09:24 -0700141#define I915_BOX_FLIP 0x2
142#define I915_BOX_WAIT 0x4
Christopher Ferris106b3a82016-08-24 12:15:38 -0700143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800144#define I915_BOX_TEXTURE_LOAD 0x8
Ben Cheng655a7c02013-10-16 16:09:24 -0700145#define I915_BOX_LOST_CONTEXT 0x10
Ben Cheng655a7c02013-10-16 16:09:24 -0700146#define DRM_I915_INIT 0x00
147#define DRM_I915_FLUSH 0x01
Christopher Ferris106b3a82016-08-24 12:15:38 -0700148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800149#define DRM_I915_FLIP 0x02
Ben Cheng655a7c02013-10-16 16:09:24 -0700150#define DRM_I915_BATCHBUFFER 0x03
Ben Cheng655a7c02013-10-16 16:09:24 -0700151#define DRM_I915_IRQ_EMIT 0x04
152#define DRM_I915_IRQ_WAIT 0x05
Christopher Ferris106b3a82016-08-24 12:15:38 -0700153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800154#define DRM_I915_GETPARAM 0x06
Ben Cheng655a7c02013-10-16 16:09:24 -0700155#define DRM_I915_SETPARAM 0x07
Ben Cheng655a7c02013-10-16 16:09:24 -0700156#define DRM_I915_ALLOC 0x08
157#define DRM_I915_FREE 0x09
Christopher Ferris106b3a82016-08-24 12:15:38 -0700158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800159#define DRM_I915_INIT_HEAP 0x0a
Ben Cheng655a7c02013-10-16 16:09:24 -0700160#define DRM_I915_CMDBUFFER 0x0b
Ben Cheng655a7c02013-10-16 16:09:24 -0700161#define DRM_I915_DESTROY_HEAP 0x0c
162#define DRM_I915_SET_VBLANK_PIPE 0x0d
Christopher Ferris106b3a82016-08-24 12:15:38 -0700163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800164#define DRM_I915_GET_VBLANK_PIPE 0x0e
Ben Cheng655a7c02013-10-16 16:09:24 -0700165#define DRM_I915_VBLANK_SWAP 0x0f
Ben Cheng655a7c02013-10-16 16:09:24 -0700166#define DRM_I915_HWS_ADDR 0x11
167#define DRM_I915_GEM_INIT 0x13
Christopher Ferris106b3a82016-08-24 12:15:38 -0700168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800169#define DRM_I915_GEM_EXECBUFFER 0x14
Ben Cheng655a7c02013-10-16 16:09:24 -0700170#define DRM_I915_GEM_PIN 0x15
Ben Cheng655a7c02013-10-16 16:09:24 -0700171#define DRM_I915_GEM_UNPIN 0x16
172#define DRM_I915_GEM_BUSY 0x17
Christopher Ferris106b3a82016-08-24 12:15:38 -0700173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800174#define DRM_I915_GEM_THROTTLE 0x18
Ben Cheng655a7c02013-10-16 16:09:24 -0700175#define DRM_I915_GEM_ENTERVT 0x19
Ben Cheng655a7c02013-10-16 16:09:24 -0700176#define DRM_I915_GEM_LEAVEVT 0x1a
177#define DRM_I915_GEM_CREATE 0x1b
Christopher Ferris106b3a82016-08-24 12:15:38 -0700178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800179#define DRM_I915_GEM_PREAD 0x1c
Ben Cheng655a7c02013-10-16 16:09:24 -0700180#define DRM_I915_GEM_PWRITE 0x1d
Ben Cheng655a7c02013-10-16 16:09:24 -0700181#define DRM_I915_GEM_MMAP 0x1e
182#define DRM_I915_GEM_SET_DOMAIN 0x1f
Christopher Ferris106b3a82016-08-24 12:15:38 -0700183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800184#define DRM_I915_GEM_SW_FINISH 0x20
Ben Cheng655a7c02013-10-16 16:09:24 -0700185#define DRM_I915_GEM_SET_TILING 0x21
Ben Cheng655a7c02013-10-16 16:09:24 -0700186#define DRM_I915_GEM_GET_TILING 0x22
187#define DRM_I915_GEM_GET_APERTURE 0x23
Christopher Ferris106b3a82016-08-24 12:15:38 -0700188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800189#define DRM_I915_GEM_MMAP_GTT 0x24
Ben Cheng655a7c02013-10-16 16:09:24 -0700190#define DRM_I915_GET_PIPE_FROM_CRTC_ID 0x25
Ben Cheng655a7c02013-10-16 16:09:24 -0700191#define DRM_I915_GEM_MADVISE 0x26
192#define DRM_I915_OVERLAY_PUT_IMAGE 0x27
Christopher Ferris106b3a82016-08-24 12:15:38 -0700193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800194#define DRM_I915_OVERLAY_ATTRS 0x28
Ben Cheng655a7c02013-10-16 16:09:24 -0700195#define DRM_I915_GEM_EXECBUFFER2 0x29
Ben Cheng655a7c02013-10-16 16:09:24 -0700196#define DRM_I915_GET_SPRITE_COLORKEY 0x2a
197#define DRM_I915_SET_SPRITE_COLORKEY 0x2b
Christopher Ferris106b3a82016-08-24 12:15:38 -0700198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800199#define DRM_I915_GEM_WAIT 0x2c
Ben Cheng655a7c02013-10-16 16:09:24 -0700200#define DRM_I915_GEM_CONTEXT_CREATE 0x2d
Ben Cheng655a7c02013-10-16 16:09:24 -0700201#define DRM_I915_GEM_CONTEXT_DESTROY 0x2e
202#define DRM_I915_GEM_SET_CACHING 0x2f
Christopher Ferris106b3a82016-08-24 12:15:38 -0700203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800204#define DRM_I915_GEM_GET_CACHING 0x30
Ben Cheng655a7c02013-10-16 16:09:24 -0700205#define DRM_I915_REG_READ 0x31
Christopher Ferris38062f92014-07-09 15:33:25 -0700206#define DRM_I915_GET_RESET_STATS 0x32
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700207#define DRM_I915_GEM_USERPTR 0x33
Christopher Ferris106b3a82016-08-24 12:15:38 -0700208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800209#define DRM_I915_GEM_CONTEXT_GETPARAM 0x34
Christopher Ferris05d08e92016-02-04 13:16:38 -0800210#define DRM_I915_GEM_CONTEXT_SETPARAM 0x35
Tao Baod7db5942015-01-28 10:07:51 -0800211#define DRM_IOCTL_I915_INIT DRM_IOW(DRM_COMMAND_BASE + DRM_I915_INIT, drm_i915_init_t)
212#define DRM_IOCTL_I915_FLUSH DRM_IO(DRM_COMMAND_BASE + DRM_I915_FLUSH)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800214#define DRM_IOCTL_I915_FLIP DRM_IO(DRM_COMMAND_BASE + DRM_I915_FLIP)
Tao Baod7db5942015-01-28 10:07:51 -0800215#define DRM_IOCTL_I915_BATCHBUFFER DRM_IOW(DRM_COMMAND_BASE + DRM_I915_BATCHBUFFER, drm_i915_batchbuffer_t)
Ben Cheng655a7c02013-10-16 16:09:24 -0700216#define DRM_IOCTL_I915_IRQ_EMIT DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_IRQ_EMIT, drm_i915_irq_emit_t)
Tao Baod7db5942015-01-28 10:07:51 -0800217#define DRM_IOCTL_I915_IRQ_WAIT DRM_IOW(DRM_COMMAND_BASE + DRM_I915_IRQ_WAIT, drm_i915_irq_wait_t)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800219#define DRM_IOCTL_I915_GETPARAM DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GETPARAM, drm_i915_getparam_t)
Tao Baod7db5942015-01-28 10:07:51 -0800220#define DRM_IOCTL_I915_SETPARAM DRM_IOW(DRM_COMMAND_BASE + DRM_I915_SETPARAM, drm_i915_setparam_t)
Ben Cheng655a7c02013-10-16 16:09:24 -0700221#define DRM_IOCTL_I915_ALLOC DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_ALLOC, drm_i915_mem_alloc_t)
Tao Baod7db5942015-01-28 10:07:51 -0800222#define DRM_IOCTL_I915_FREE DRM_IOW(DRM_COMMAND_BASE + DRM_I915_FREE, drm_i915_mem_free_t)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800224#define DRM_IOCTL_I915_INIT_HEAP DRM_IOW(DRM_COMMAND_BASE + DRM_I915_INIT_HEAP, drm_i915_mem_init_heap_t)
Tao Baod7db5942015-01-28 10:07:51 -0800225#define DRM_IOCTL_I915_CMDBUFFER DRM_IOW(DRM_COMMAND_BASE + DRM_I915_CMDBUFFER, drm_i915_cmdbuffer_t)
226#define DRM_IOCTL_I915_DESTROY_HEAP DRM_IOW(DRM_COMMAND_BASE + DRM_I915_DESTROY_HEAP, drm_i915_mem_destroy_heap_t)
227#define DRM_IOCTL_I915_SET_VBLANK_PIPE DRM_IOW(DRM_COMMAND_BASE + DRM_I915_SET_VBLANK_PIPE, drm_i915_vblank_pipe_t)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700228/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800229#define DRM_IOCTL_I915_GET_VBLANK_PIPE DRM_IOR(DRM_COMMAND_BASE + DRM_I915_GET_VBLANK_PIPE, drm_i915_vblank_pipe_t)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700230#define DRM_IOCTL_I915_VBLANK_SWAP DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_VBLANK_SWAP, drm_i915_vblank_swap_t)
Ben Cheng655a7c02013-10-16 16:09:24 -0700231#define DRM_IOCTL_I915_HWS_ADDR DRM_IOW(DRM_COMMAND_BASE + DRM_I915_HWS_ADDR, struct drm_i915_gem_init)
232#define DRM_IOCTL_I915_GEM_INIT DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_INIT, struct drm_i915_gem_init)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700233/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800234#define DRM_IOCTL_I915_GEM_EXECBUFFER DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_EXECBUFFER, struct drm_i915_gem_execbuffer)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700235#define DRM_IOCTL_I915_GEM_EXECBUFFER2 DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_EXECBUFFER2, struct drm_i915_gem_execbuffer2)
Ben Cheng655a7c02013-10-16 16:09:24 -0700236#define DRM_IOCTL_I915_GEM_PIN DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_PIN, struct drm_i915_gem_pin)
237#define DRM_IOCTL_I915_GEM_UNPIN DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_UNPIN, struct drm_i915_gem_unpin)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700238/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800239#define DRM_IOCTL_I915_GEM_BUSY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_BUSY, struct drm_i915_gem_busy)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700240#define DRM_IOCTL_I915_GEM_SET_CACHING DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_SET_CACHING, struct drm_i915_gem_caching)
Ben Cheng655a7c02013-10-16 16:09:24 -0700241#define DRM_IOCTL_I915_GEM_GET_CACHING DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_GET_CACHING, struct drm_i915_gem_caching)
Tao Baod7db5942015-01-28 10:07:51 -0800242#define DRM_IOCTL_I915_GEM_THROTTLE DRM_IO(DRM_COMMAND_BASE + DRM_I915_GEM_THROTTLE)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700243/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800244#define DRM_IOCTL_I915_GEM_ENTERVT DRM_IO(DRM_COMMAND_BASE + DRM_I915_GEM_ENTERVT)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700245#define DRM_IOCTL_I915_GEM_LEAVEVT DRM_IO(DRM_COMMAND_BASE + DRM_I915_GEM_LEAVEVT)
Ben Cheng655a7c02013-10-16 16:09:24 -0700246#define DRM_IOCTL_I915_GEM_CREATE DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CREATE, struct drm_i915_gem_create)
Tao Baod7db5942015-01-28 10:07:51 -0800247#define DRM_IOCTL_I915_GEM_PREAD DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_PREAD, struct drm_i915_gem_pread)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700248/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800249#define DRM_IOCTL_I915_GEM_PWRITE DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_PWRITE, struct drm_i915_gem_pwrite)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700250#define DRM_IOCTL_I915_GEM_MMAP DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_MMAP, struct drm_i915_gem_mmap)
Ben Cheng655a7c02013-10-16 16:09:24 -0700251#define DRM_IOCTL_I915_GEM_MMAP_GTT DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_MMAP_GTT, struct drm_i915_gem_mmap_gtt)
Tao Baod7db5942015-01-28 10:07:51 -0800252#define DRM_IOCTL_I915_GEM_SET_DOMAIN DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_SET_DOMAIN, struct drm_i915_gem_set_domain)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700253/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800254#define DRM_IOCTL_I915_GEM_SW_FINISH DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_SW_FINISH, struct drm_i915_gem_sw_finish)
Tao Baod7db5942015-01-28 10:07:51 -0800255#define DRM_IOCTL_I915_GEM_SET_TILING DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_SET_TILING, struct drm_i915_gem_set_tiling)
256#define DRM_IOCTL_I915_GEM_GET_TILING DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_GET_TILING, struct drm_i915_gem_get_tiling)
257#define DRM_IOCTL_I915_GEM_GET_APERTURE DRM_IOR(DRM_COMMAND_BASE + DRM_I915_GEM_GET_APERTURE, struct drm_i915_gem_get_aperture)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700258/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800259#define DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_PIPE_FROM_CRTC_ID, struct drm_i915_get_pipe_from_crtc_id)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700260#define DRM_IOCTL_I915_GEM_MADVISE DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_MADVISE, struct drm_i915_gem_madvise)
Ben Cheng655a7c02013-10-16 16:09:24 -0700261#define DRM_IOCTL_I915_OVERLAY_PUT_IMAGE DRM_IOW(DRM_COMMAND_BASE + DRM_I915_OVERLAY_PUT_IMAGE, struct drm_intel_overlay_put_image)
262#define DRM_IOCTL_I915_OVERLAY_ATTRS DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_OVERLAY_ATTRS, struct drm_intel_overlay_attrs)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700263/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800264#define DRM_IOCTL_I915_SET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_SET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800265#define DRM_IOCTL_I915_GET_SPRITE_COLORKEY DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_SPRITE_COLORKEY, struct drm_intel_sprite_colorkey)
Ben Cheng655a7c02013-10-16 16:09:24 -0700266#define DRM_IOCTL_I915_GEM_WAIT DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_WAIT, struct drm_i915_gem_wait)
Tao Baod7db5942015-01-28 10:07:51 -0800267#define DRM_IOCTL_I915_GEM_CONTEXT_CREATE DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_CREATE, struct drm_i915_gem_context_create)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700268/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800269#define DRM_IOCTL_I915_GEM_CONTEXT_DESTROY DRM_IOW(DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_DESTROY, struct drm_i915_gem_context_destroy)
Tao Baod7db5942015-01-28 10:07:51 -0800270#define DRM_IOCTL_I915_REG_READ DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_REG_READ, struct drm_i915_reg_read)
271#define DRM_IOCTL_I915_GET_RESET_STATS DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GET_RESET_STATS, struct drm_i915_reset_stats)
272#define DRM_IOCTL_I915_GEM_USERPTR DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_USERPTR, struct drm_i915_gem_userptr)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700273/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800274#define DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_GETPARAM, struct drm_i915_gem_context_param)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800275#define DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CONTEXT_SETPARAM, struct drm_i915_gem_context_param)
Ben Cheng655a7c02013-10-16 16:09:24 -0700276typedef struct drm_i915_batchbuffer {
Tao Baod7db5942015-01-28 10:07:51 -0800277 int start;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700278/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800279 int used;
Tao Baod7db5942015-01-28 10:07:51 -0800280 int DR1;
281 int DR4;
Tao Baod7db5942015-01-28 10:07:51 -0800282 int num_cliprects;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700283/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800284 struct drm_clip_rect __user * cliprects;
Christopher Ferris38062f92014-07-09 15:33:25 -0700285} drm_i915_batchbuffer_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700286typedef struct _drm_i915_cmdbuffer {
Tao Baod7db5942015-01-28 10:07:51 -0800287 char __user * buf;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700288/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800289 int sz;
Tao Baod7db5942015-01-28 10:07:51 -0800290 int DR1;
291 int DR4;
Tao Baod7db5942015-01-28 10:07:51 -0800292 int num_cliprects;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700293/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800294 struct drm_clip_rect __user * cliprects;
Christopher Ferris38062f92014-07-09 15:33:25 -0700295} drm_i915_cmdbuffer_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700296typedef struct drm_i915_irq_emit {
Tao Baod7db5942015-01-28 10:07:51 -0800297 int __user * irq_seq;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700298/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800299} drm_i915_irq_emit_t;
Christopher Ferris38062f92014-07-09 15:33:25 -0700300typedef struct drm_i915_irq_wait {
Tao Baod7db5942015-01-28 10:07:51 -0800301 int irq_seq;
Ben Cheng655a7c02013-10-16 16:09:24 -0700302} drm_i915_irq_wait_t;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700303/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800304#define I915_PARAM_IRQ_ACTIVE 1
Christopher Ferris38062f92014-07-09 15:33:25 -0700305#define I915_PARAM_ALLOW_BATCHBUFFER 2
Ben Cheng655a7c02013-10-16 16:09:24 -0700306#define I915_PARAM_LAST_DISPATCH 3
307#define I915_PARAM_CHIPSET_ID 4
Christopher Ferris106b3a82016-08-24 12:15:38 -0700308/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800309#define I915_PARAM_HAS_GEM 5
Christopher Ferris38062f92014-07-09 15:33:25 -0700310#define I915_PARAM_NUM_FENCES_AVAIL 6
Ben Cheng655a7c02013-10-16 16:09:24 -0700311#define I915_PARAM_HAS_OVERLAY 7
312#define I915_PARAM_HAS_PAGEFLIPPING 8
Christopher Ferris106b3a82016-08-24 12:15:38 -0700313/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800314#define I915_PARAM_HAS_EXECBUF2 9
Christopher Ferris38062f92014-07-09 15:33:25 -0700315#define I915_PARAM_HAS_BSD 10
Ben Cheng655a7c02013-10-16 16:09:24 -0700316#define I915_PARAM_HAS_BLT 11
317#define I915_PARAM_HAS_RELAXED_FENCING 12
Christopher Ferris106b3a82016-08-24 12:15:38 -0700318/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800319#define I915_PARAM_HAS_COHERENT_RINGS 13
Christopher Ferris38062f92014-07-09 15:33:25 -0700320#define I915_PARAM_HAS_EXEC_CONSTANTS 14
Ben Cheng655a7c02013-10-16 16:09:24 -0700321#define I915_PARAM_HAS_RELAXED_DELTA 15
322#define I915_PARAM_HAS_GEN7_SOL_RESET 16
Christopher Ferris106b3a82016-08-24 12:15:38 -0700323/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800324#define I915_PARAM_HAS_LLC 17
Christopher Ferris38062f92014-07-09 15:33:25 -0700325#define I915_PARAM_HAS_ALIASING_PPGTT 18
Ben Cheng655a7c02013-10-16 16:09:24 -0700326#define I915_PARAM_HAS_WAIT_TIMEOUT 19
327#define I915_PARAM_HAS_SEMAPHORES 20
Christopher Ferris106b3a82016-08-24 12:15:38 -0700328/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800329#define I915_PARAM_HAS_PRIME_VMAP_FLUSH 21
Christopher Ferris38062f92014-07-09 15:33:25 -0700330#define I915_PARAM_HAS_VEBOX 22
Ben Cheng655a7c02013-10-16 16:09:24 -0700331#define I915_PARAM_HAS_SECURE_BATCHES 23
332#define I915_PARAM_HAS_PINNED_BATCHES 24
Christopher Ferris106b3a82016-08-24 12:15:38 -0700333/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800334#define I915_PARAM_HAS_EXEC_NO_RELOC 25
Christopher Ferris38062f92014-07-09 15:33:25 -0700335#define I915_PARAM_HAS_EXEC_HANDLE_LUT 26
336#define I915_PARAM_HAS_WT 27
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700337#define I915_PARAM_CMD_PARSER_VERSION 28
Christopher Ferris106b3a82016-08-24 12:15:38 -0700338/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800339#define I915_PARAM_HAS_COHERENT_PHYS_GTT 29
Christopher Ferris05d08e92016-02-04 13:16:38 -0800340#define I915_PARAM_MMAP_VERSION 30
341#define I915_PARAM_HAS_BSD2 31
Christopher Ferris05d08e92016-02-04 13:16:38 -0800342#define I915_PARAM_REVISION 32
Christopher Ferris106b3a82016-08-24 12:15:38 -0700343/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800344#define I915_PARAM_SUBSLICE_TOTAL 33
Christopher Ferris05d08e92016-02-04 13:16:38 -0800345#define I915_PARAM_EU_TOTAL 34
346#define I915_PARAM_HAS_GPU_RESET 35
Christopher Ferris05d08e92016-02-04 13:16:38 -0800347#define I915_PARAM_HAS_RESOURCE_STREAMER 36
Christopher Ferris106b3a82016-08-24 12:15:38 -0700348/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800349#define I915_PARAM_HAS_EXEC_SOFTPIN 37
Christopher Ferris49f525c2016-12-12 14:55:36 -0800350#define I915_PARAM_HAS_POOLED_EU 38
351#define I915_PARAM_MIN_EU_IN_POOL 39
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800352#define I915_PARAM_MMAP_GTT_VERSION 40
353/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800354#define I915_PARAM_HAS_SCHEDULER 41
Ben Cheng655a7c02013-10-16 16:09:24 -0700355typedef struct drm_i915_getparam {
Christopher Ferris05d08e92016-02-04 13:16:38 -0800356 __s32 param;
Tao Baod7db5942015-01-28 10:07:51 -0800357 int __user * value;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800358/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800359} drm_i915_getparam_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700360#define I915_SETPARAM_USE_MI_BATCHBUFFER_START 1
361#define I915_SETPARAM_TEX_LRU_LOG_GRANULARITY 2
362#define I915_SETPARAM_ALLOW_BATCHBUFFER 3
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800363/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800364#define I915_SETPARAM_NUM_USED_FENCES 4
Ben Cheng655a7c02013-10-16 16:09:24 -0700365typedef struct drm_i915_setparam {
Tao Baod7db5942015-01-28 10:07:51 -0800366 int param;
367 int value;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800368/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800369} drm_i915_setparam_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700370#define I915_MEM_REGION_AGP 1
371typedef struct drm_i915_mem_alloc {
Tao Baod7db5942015-01-28 10:07:51 -0800372 int region;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800373/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800374 int alignment;
Tao Baod7db5942015-01-28 10:07:51 -0800375 int size;
376 int __user * region_offset;
Ben Cheng655a7c02013-10-16 16:09:24 -0700377} drm_i915_mem_alloc_t;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800378/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800379typedef struct drm_i915_mem_free {
Tao Baod7db5942015-01-28 10:07:51 -0800380 int region;
381 int region_offset;
Ben Cheng655a7c02013-10-16 16:09:24 -0700382} drm_i915_mem_free_t;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800383/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800384typedef struct drm_i915_mem_init_heap {
Tao Baod7db5942015-01-28 10:07:51 -0800385 int region;
386 int size;
387 int start;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800388/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800389} drm_i915_mem_init_heap_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700390typedef struct drm_i915_mem_destroy_heap {
Tao Baod7db5942015-01-28 10:07:51 -0800391 int region;
Ben Cheng655a7c02013-10-16 16:09:24 -0700392} drm_i915_mem_destroy_heap_t;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800393/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800394#define DRM_I915_VBLANK_PIPE_A 1
Ben Cheng655a7c02013-10-16 16:09:24 -0700395#define DRM_I915_VBLANK_PIPE_B 2
396typedef struct drm_i915_vblank_pipe {
Tao Baod7db5942015-01-28 10:07:51 -0800397 int pipe;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800398/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800399} drm_i915_vblank_pipe_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700400typedef struct drm_i915_vblank_swap {
Tao Baod7db5942015-01-28 10:07:51 -0800401 drm_drawable_t drawable;
402 enum drm_vblank_seq_type seqtype;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800403/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800404 unsigned int sequence;
Ben Cheng655a7c02013-10-16 16:09:24 -0700405} drm_i915_vblank_swap_t;
406typedef struct drm_i915_hws_addr {
Tao Baod7db5942015-01-28 10:07:51 -0800407 __u64 addr;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800408/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800409} drm_i915_hws_addr_t;
Ben Cheng655a7c02013-10-16 16:09:24 -0700410struct drm_i915_gem_init {
Tao Baod7db5942015-01-28 10:07:51 -0800411 __u64 gtt_start;
412 __u64 gtt_end;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800413/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800414};
Ben Cheng655a7c02013-10-16 16:09:24 -0700415struct drm_i915_gem_create {
Tao Baod7db5942015-01-28 10:07:51 -0800416 __u64 size;
417 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800418/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800419 __u32 pad;
Ben Cheng655a7c02013-10-16 16:09:24 -0700420};
421struct drm_i915_gem_pread {
Tao Baod7db5942015-01-28 10:07:51 -0800422 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800423/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800424 __u32 pad;
Tao Baod7db5942015-01-28 10:07:51 -0800425 __u64 offset;
426 __u64 size;
427 __u64 data_ptr;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800428/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800429};
Ben Cheng655a7c02013-10-16 16:09:24 -0700430struct drm_i915_gem_pwrite {
Tao Baod7db5942015-01-28 10:07:51 -0800431 __u32 handle;
432 __u32 pad;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800433/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800434 __u64 offset;
Tao Baod7db5942015-01-28 10:07:51 -0800435 __u64 size;
436 __u64 data_ptr;
Ben Cheng655a7c02013-10-16 16:09:24 -0700437};
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800438/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800439struct drm_i915_gem_mmap {
Tao Baod7db5942015-01-28 10:07:51 -0800440 __u32 handle;
441 __u32 pad;
442 __u64 offset;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800443/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800444 __u64 size;
Tao Baod7db5942015-01-28 10:07:51 -0800445 __u64 addr_ptr;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800446 __u64 flags;
447#define I915_MMAP_WC 0x1
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800448/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800449};
Ben Cheng655a7c02013-10-16 16:09:24 -0700450struct drm_i915_gem_mmap_gtt {
Tao Baod7db5942015-01-28 10:07:51 -0800451 __u32 handle;
452 __u32 pad;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800453/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800454 __u64 offset;
Ben Cheng655a7c02013-10-16 16:09:24 -0700455};
456struct drm_i915_gem_set_domain {
Tao Baod7db5942015-01-28 10:07:51 -0800457 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800458/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800459 __u32 read_domains;
Tao Baod7db5942015-01-28 10:07:51 -0800460 __u32 write_domain;
Ben Cheng655a7c02013-10-16 16:09:24 -0700461};
Ben Cheng655a7c02013-10-16 16:09:24 -0700462struct drm_i915_gem_sw_finish {
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800463/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800464 __u32 handle;
Ben Cheng655a7c02013-10-16 16:09:24 -0700465};
466struct drm_i915_gem_relocation_entry {
Tao Baod7db5942015-01-28 10:07:51 -0800467 __u32 target_handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800468/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800469 __u32 delta;
Tao Baod7db5942015-01-28 10:07:51 -0800470 __u64 offset;
Tao Baod7db5942015-01-28 10:07:51 -0800471 __u64 presumed_offset;
472 __u32 read_domains;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800473/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800474 __u32 write_domain;
Ben Cheng655a7c02013-10-16 16:09:24 -0700475};
476#define I915_GEM_DOMAIN_CPU 0x00000001
Ben Cheng655a7c02013-10-16 16:09:24 -0700477#define I915_GEM_DOMAIN_RENDER 0x00000002
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800478/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800479#define I915_GEM_DOMAIN_SAMPLER 0x00000004
Ben Cheng655a7c02013-10-16 16:09:24 -0700480#define I915_GEM_DOMAIN_COMMAND 0x00000008
481#define I915_GEM_DOMAIN_INSTRUCTION 0x00000010
Ben Cheng655a7c02013-10-16 16:09:24 -0700482#define I915_GEM_DOMAIN_VERTEX 0x00000020
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800483/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800484#define I915_GEM_DOMAIN_GTT 0x00000040
Ben Cheng655a7c02013-10-16 16:09:24 -0700485struct drm_i915_gem_exec_object {
Tao Baod7db5942015-01-28 10:07:51 -0800486 __u32 handle;
487 __u32 relocation_count;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800488/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800489 __u64 relocs_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800490 __u64 alignment;
Tao Baod7db5942015-01-28 10:07:51 -0800491 __u64 offset;
Ben Cheng655a7c02013-10-16 16:09:24 -0700492};
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800493/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800494struct drm_i915_gem_execbuffer {
Tao Baod7db5942015-01-28 10:07:51 -0800495 __u64 buffers_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800496 __u32 buffer_count;
497 __u32 batch_start_offset;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800498/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800499 __u32 batch_len;
Tao Baod7db5942015-01-28 10:07:51 -0800500 __u32 DR1;
Tao Baod7db5942015-01-28 10:07:51 -0800501 __u32 DR4;
502 __u32 num_cliprects;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800503/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800504 __u64 cliprects_ptr;
Ben Cheng655a7c02013-10-16 16:09:24 -0700505};
506struct drm_i915_gem_exec_object2 {
Tao Baod7db5942015-01-28 10:07:51 -0800507 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800508/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800509 __u32 relocation_count;
Tao Baod7db5942015-01-28 10:07:51 -0800510 __u64 relocs_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800511 __u64 alignment;
512 __u64 offset;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800513/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800514#define EXEC_OBJECT_NEEDS_FENCE (1 << 0)
Tao Baod7db5942015-01-28 10:07:51 -0800515#define EXEC_OBJECT_NEEDS_GTT (1 << 1)
Tao Baod7db5942015-01-28 10:07:51 -0800516#define EXEC_OBJECT_WRITE (1 << 2)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800517#define EXEC_OBJECT_SUPPORTS_48B_ADDRESS (1 << 3)
Christopher Ferris49f525c2016-12-12 14:55:36 -0800518/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800519#define EXEC_OBJECT_PINNED (1 << 4)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800520#define EXEC_OBJECT_PAD_TO_SIZE (1 << 5)
521#define __EXEC_OBJECT_UNKNOWN_FLAGS - (EXEC_OBJECT_PAD_TO_SIZE << 1)
522 __u64 flags;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800523/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800524 union {
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800525 __u64 rsvd1;
526 __u64 pad_to_size;
527 };
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800528/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800529 __u64 rsvd2;
Ben Cheng655a7c02013-10-16 16:09:24 -0700530};
531struct drm_i915_gem_execbuffer2 {
Tao Baod7db5942015-01-28 10:07:51 -0800532 __u64 buffers_ptr;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800533/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800534 __u32 buffer_count;
Tao Baod7db5942015-01-28 10:07:51 -0800535 __u32 batch_start_offset;
536 __u32 batch_len;
537 __u32 DR1;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800538/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800539 __u32 DR4;
Tao Baod7db5942015-01-28 10:07:51 -0800540 __u32 num_cliprects;
541 __u64 cliprects_ptr;
542#define I915_EXEC_RING_MASK (7 << 0)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800543/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800544#define I915_EXEC_DEFAULT (0 << 0)
Tao Baod7db5942015-01-28 10:07:51 -0800545#define I915_EXEC_RENDER (1 << 0)
546#define I915_EXEC_BSD (2 << 0)
547#define I915_EXEC_BLT (3 << 0)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800548/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800549#define I915_EXEC_VEBOX (4 << 0)
Tao Baod7db5942015-01-28 10:07:51 -0800550#define I915_EXEC_CONSTANTS_MASK (3 << 6)
551#define I915_EXEC_CONSTANTS_REL_GENERAL (0 << 6)
552#define I915_EXEC_CONSTANTS_ABSOLUTE (1 << 6)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800553/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800554#define I915_EXEC_CONSTANTS_REL_SURFACE (2 << 6)
Tao Baod7db5942015-01-28 10:07:51 -0800555 __u64 flags;
556 __u64 rsvd1;
557 __u64 rsvd2;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800558/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800559};
Tao Baod7db5942015-01-28 10:07:51 -0800560#define I915_EXEC_GEN7_SOL_RESET (1 << 8)
561#define I915_EXEC_SECURE (1 << 9)
562#define I915_EXEC_IS_PINNED (1 << 10)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800563/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800564#define I915_EXEC_NO_RELOC (1 << 11)
Tao Baod7db5942015-01-28 10:07:51 -0800565#define I915_EXEC_HANDLE_LUT (1 << 12)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700566#define I915_EXEC_BSD_SHIFT (13)
567#define I915_EXEC_BSD_MASK (3 << I915_EXEC_BSD_SHIFT)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800568/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800569#define I915_EXEC_BSD_DEFAULT (0 << I915_EXEC_BSD_SHIFT)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700570#define I915_EXEC_BSD_RING1 (1 << I915_EXEC_BSD_SHIFT)
571#define I915_EXEC_BSD_RING2 (2 << I915_EXEC_BSD_SHIFT)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800572#define I915_EXEC_RESOURCE_STREAMER (1 << 15)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800573/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800574#define __I915_EXEC_UNKNOWN_FLAGS - (I915_EXEC_RESOURCE_STREAMER << 1)
Christopher Ferris106b3a82016-08-24 12:15:38 -0700575#define I915_EXEC_CONTEXT_ID_MASK (0xffffffff)
Tao Baod7db5942015-01-28 10:07:51 -0800576#define i915_execbuffer2_set_context_id(eb2,context) (eb2).rsvd1 = context & I915_EXEC_CONTEXT_ID_MASK
577#define i915_execbuffer2_get_context_id(eb2) ((eb2).rsvd1 & I915_EXEC_CONTEXT_ID_MASK)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800578/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800579struct drm_i915_gem_pin {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700580 __u32 handle;
Tao Baod7db5942015-01-28 10:07:51 -0800581 __u32 pad;
582 __u64 alignment;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800583/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800584 __u64 offset;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700585};
Ben Cheng655a7c02013-10-16 16:09:24 -0700586struct drm_i915_gem_unpin {
Tao Baod7db5942015-01-28 10:07:51 -0800587 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800588/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800589 __u32 pad;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700590};
Ben Cheng655a7c02013-10-16 16:09:24 -0700591struct drm_i915_gem_busy {
Tao Baod7db5942015-01-28 10:07:51 -0800592 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800593/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800594 __u32 busy;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700595};
Ben Cheng655a7c02013-10-16 16:09:24 -0700596#define I915_CACHING_NONE 0
Ben Cheng655a7c02013-10-16 16:09:24 -0700597#define I915_CACHING_CACHED 1
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800598/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800599#define I915_CACHING_DISPLAY 2
Christopher Ferris106b3a82016-08-24 12:15:38 -0700600struct drm_i915_gem_caching {
Tao Baod7db5942015-01-28 10:07:51 -0800601 __u32 handle;
602 __u32 caching;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800603/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800604};
Christopher Ferris106b3a82016-08-24 12:15:38 -0700605#define I915_TILING_NONE 0
Ben Cheng655a7c02013-10-16 16:09:24 -0700606#define I915_TILING_X 1
607#define I915_TILING_Y 2
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800608/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800609#define I915_TILING_LAST I915_TILING_Y
Ben Cheng655a7c02013-10-16 16:09:24 -0700610#define I915_BIT_6_SWIZZLE_NONE 0
Christopher Ferris106b3a82016-08-24 12:15:38 -0700611#define I915_BIT_6_SWIZZLE_9 1
Ben Cheng655a7c02013-10-16 16:09:24 -0700612#define I915_BIT_6_SWIZZLE_9_10 2
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800613/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800614#define I915_BIT_6_SWIZZLE_9_11 3
Ben Cheng655a7c02013-10-16 16:09:24 -0700615#define I915_BIT_6_SWIZZLE_9_10_11 4
Christopher Ferris106b3a82016-08-24 12:15:38 -0700616#define I915_BIT_6_SWIZZLE_UNKNOWN 5
Ben Cheng655a7c02013-10-16 16:09:24 -0700617#define I915_BIT_6_SWIZZLE_9_17 6
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800618/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800619#define I915_BIT_6_SWIZZLE_9_10_17 7
Ben Cheng655a7c02013-10-16 16:09:24 -0700620struct drm_i915_gem_set_tiling {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700621 __u32 handle;
Tao Baod7db5942015-01-28 10:07:51 -0800622 __u32 tiling_mode;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800623/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800624 __u32 stride;
Tao Baod7db5942015-01-28 10:07:51 -0800625 __u32 swizzle_mode;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700626};
Ben Cheng655a7c02013-10-16 16:09:24 -0700627struct drm_i915_gem_get_tiling {
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800628/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800629 __u32 handle;
Tao Baod7db5942015-01-28 10:07:51 -0800630 __u32 tiling_mode;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700631 __u32 swizzle_mode;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800632 __u32 phys_swizzle_mode;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800633/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800634};
Ben Cheng655a7c02013-10-16 16:09:24 -0700635struct drm_i915_gem_get_aperture {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700636 __u64 aper_size;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800637 __u64 aper_available_size;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800638/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800639};
Ben Cheng655a7c02013-10-16 16:09:24 -0700640struct drm_i915_get_pipe_from_crtc_id {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700641 __u32 crtc_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800642 __u32 pipe;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800643/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800644};
Ben Cheng655a7c02013-10-16 16:09:24 -0700645#define I915_MADV_WILLNEED 0
Christopher Ferris106b3a82016-08-24 12:15:38 -0700646#define I915_MADV_DONTNEED 1
Christopher Ferris05d08e92016-02-04 13:16:38 -0800647#define __I915_MADV_PURGED 2
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800648/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800649struct drm_i915_gem_madvise {
Tao Baod7db5942015-01-28 10:07:51 -0800650 __u32 handle;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700651 __u32 madv;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800652 __u32 retained;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800653/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800654};
Ben Cheng655a7c02013-10-16 16:09:24 -0700655#define I915_OVERLAY_TYPE_MASK 0xff
Christopher Ferris106b3a82016-08-24 12:15:38 -0700656#define I915_OVERLAY_YUV_PLANAR 0x01
Christopher Ferris05d08e92016-02-04 13:16:38 -0800657#define I915_OVERLAY_YUV_PACKED 0x02
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800658/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800659#define I915_OVERLAY_RGB 0x03
Ben Cheng655a7c02013-10-16 16:09:24 -0700660#define I915_OVERLAY_DEPTH_MASK 0xff00
Christopher Ferris106b3a82016-08-24 12:15:38 -0700661#define I915_OVERLAY_RGB24 0x1000
Christopher Ferris05d08e92016-02-04 13:16:38 -0800662#define I915_OVERLAY_RGB16 0x2000
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800663/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800664#define I915_OVERLAY_RGB15 0x3000
Ben Cheng655a7c02013-10-16 16:09:24 -0700665#define I915_OVERLAY_YUV422 0x0100
Christopher Ferris106b3a82016-08-24 12:15:38 -0700666#define I915_OVERLAY_YUV411 0x0200
Christopher Ferris05d08e92016-02-04 13:16:38 -0800667#define I915_OVERLAY_YUV420 0x0300
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800668/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800669#define I915_OVERLAY_YUV410 0x0400
Ben Cheng655a7c02013-10-16 16:09:24 -0700670#define I915_OVERLAY_SWAP_MASK 0xff0000
Christopher Ferris106b3a82016-08-24 12:15:38 -0700671#define I915_OVERLAY_NO_SWAP 0x000000
Christopher Ferris05d08e92016-02-04 13:16:38 -0800672#define I915_OVERLAY_UV_SWAP 0x010000
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800673/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800674#define I915_OVERLAY_Y_SWAP 0x020000
Ben Cheng655a7c02013-10-16 16:09:24 -0700675#define I915_OVERLAY_Y_AND_UV_SWAP 0x030000
Christopher Ferris106b3a82016-08-24 12:15:38 -0700676#define I915_OVERLAY_FLAGS_MASK 0xff000000
Christopher Ferris05d08e92016-02-04 13:16:38 -0800677#define I915_OVERLAY_ENABLE 0x01000000
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800678/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800679struct drm_intel_overlay_put_image {
Tao Baod7db5942015-01-28 10:07:51 -0800680 __u32 flags;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700681 __u32 bo_handle;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800682 __u16 stride_Y;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800683/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800684 __u16 stride_UV;
Tao Baod7db5942015-01-28 10:07:51 -0800685 __u32 offset_Y;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700686 __u32 offset_U;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800687 __u32 offset_V;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800688/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800689 __u16 src_width;
Tao Baod7db5942015-01-28 10:07:51 -0800690 __u16 src_height;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700691 __u16 src_scan_width;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800692 __u16 src_scan_height;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800693/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800694 __u32 crtc_id;
Tao Baod7db5942015-01-28 10:07:51 -0800695 __u16 dst_x;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700696 __u16 dst_y;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800697 __u16 dst_width;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800698/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800699 __u16 dst_height;
Ben Cheng655a7c02013-10-16 16:09:24 -0700700};
Christopher Ferris106b3a82016-08-24 12:15:38 -0700701#define I915_OVERLAY_UPDATE_ATTRS (1 << 0)
Christopher Ferris05d08e92016-02-04 13:16:38 -0800702#define I915_OVERLAY_UPDATE_GAMMA (1 << 1)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800703/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800704#define I915_OVERLAY_DISABLE_DEST_COLORKEY (1 << 2)
Ben Cheng655a7c02013-10-16 16:09:24 -0700705struct drm_intel_overlay_attrs {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700706 __u32 flags;
Tao Baod7db5942015-01-28 10:07:51 -0800707 __u32 color_key;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800708/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800709 __s32 brightness;
Tao Baod7db5942015-01-28 10:07:51 -0800710 __u32 contrast;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700711 __u32 saturation;
Tao Baod7db5942015-01-28 10:07:51 -0800712 __u32 gamma0;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800713/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800714 __u32 gamma1;
Tao Baod7db5942015-01-28 10:07:51 -0800715 __u32 gamma2;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700716 __u32 gamma3;
Tao Baod7db5942015-01-28 10:07:51 -0800717 __u32 gamma4;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800718/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800719 __u32 gamma5;
Ben Cheng655a7c02013-10-16 16:09:24 -0700720};
Christopher Ferris106b3a82016-08-24 12:15:38 -0700721#define I915_SET_COLORKEY_NONE (1 << 0)
Tao Baod7db5942015-01-28 10:07:51 -0800722#define I915_SET_COLORKEY_DESTINATION (1 << 1)
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800723/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800724#define I915_SET_COLORKEY_SOURCE (1 << 2)
Ben Cheng655a7c02013-10-16 16:09:24 -0700725struct drm_intel_sprite_colorkey {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700726 __u32 plane_id;
Tao Baod7db5942015-01-28 10:07:51 -0800727 __u32 min_value;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800728/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800729 __u32 channel_mask;
Tao Baod7db5942015-01-28 10:07:51 -0800730 __u32 max_value;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700731 __u32 flags;
Ben Cheng655a7c02013-10-16 16:09:24 -0700732};
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800733/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800734struct drm_i915_gem_wait {
Tao Baod7db5942015-01-28 10:07:51 -0800735 __u32 bo_handle;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700736 __u32 flags;
Tao Baod7db5942015-01-28 10:07:51 -0800737 __s64 timeout_ns;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800738/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800739};
Ben Cheng655a7c02013-10-16 16:09:24 -0700740struct drm_i915_gem_context_create {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700741 __u32 ctx_id;
Tao Baod7db5942015-01-28 10:07:51 -0800742 __u32 pad;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800743/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800744};
Ben Cheng655a7c02013-10-16 16:09:24 -0700745struct drm_i915_gem_context_destroy {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700746 __u32 ctx_id;
Tao Baod7db5942015-01-28 10:07:51 -0800747 __u32 pad;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800748/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800749};
Ben Cheng655a7c02013-10-16 16:09:24 -0700750struct drm_i915_reg_read {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700751 __u64 offset;
Tao Baod7db5942015-01-28 10:07:51 -0800752 __u64 val;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800753/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800754};
Christopher Ferris38062f92014-07-09 15:33:25 -0700755struct drm_i915_reset_stats {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700756 __u32 ctx_id;
Tao Baod7db5942015-01-28 10:07:51 -0800757 __u32 flags;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800758/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800759 __u32 reset_count;
Tao Baod7db5942015-01-28 10:07:51 -0800760 __u32 batch_active;
Christopher Ferris106b3a82016-08-24 12:15:38 -0700761 __u32 batch_pending;
Tao Baod7db5942015-01-28 10:07:51 -0800762 __u32 pad;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800763/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800764};
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700765struct drm_i915_gem_userptr {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700766 __u64 user_ptr;
Tao Baod7db5942015-01-28 10:07:51 -0800767 __u64 user_size;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800768/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800769 __u32 flags;
Christopher Ferrisba8d4f42014-09-03 19:56:49 -0700770#define I915_USERPTR_READ_ONLY 0x1
Christopher Ferris106b3a82016-08-24 12:15:38 -0700771#define I915_USERPTR_UNSYNCHRONIZED 0x80000000
Tao Baod7db5942015-01-28 10:07:51 -0800772 __u32 handle;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800773/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800774};
Christopher Ferris05d08e92016-02-04 13:16:38 -0800775struct drm_i915_gem_context_param {
Christopher Ferris106b3a82016-08-24 12:15:38 -0700776 __u32 ctx_id;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800777 __u32 size;
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800778/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800779 __u64 param;
Christopher Ferris05d08e92016-02-04 13:16:38 -0800780#define I915_CONTEXT_PARAM_BAN_PERIOD 0x1
Christopher Ferris106b3a82016-08-24 12:15:38 -0700781#define I915_CONTEXT_PARAM_NO_ZEROMAP 0x2
782#define I915_CONTEXT_PARAM_GTT_SIZE 0x3
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800783/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800784#define I915_CONTEXT_PARAM_NO_ERROR_CAPTURE 0x4
Christopher Ferris05d08e92016-02-04 13:16:38 -0800785 __u64 value;
786};
Christopher Ferris106b3a82016-08-24 12:15:38 -0700787#ifdef __cplusplus
Christopher Ferris6a9755d2017-01-13 14:09:31 -0800788/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Ben Cheng655a7c02013-10-16 16:09:24 -0700789#endif
Christopher Ferris48af7cb2017-02-21 12:35:09 -0800790#endif