blob: 972154915f01a368e86f0dbc5443cb378d960a12 [file] [log] [blame]
Dima Zavin81fa6d52009-08-05 17:51:29 -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 ***
Ben Cheng654325d2012-03-07 21:13:49 -080010 *** 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 ***
Dima Zavin81fa6d52009-08-05 17:51:29 -070017 ****************************************************************************
18 ****************************************************************************/
19#ifndef _MSM_KGSL_H
20#define _MSM_KGSL_H
Naseer Ahmed240b3342012-06-18 14:54:42 -070021#define KGSL_VERSION_MAJOR 3
22#define KGSL_VERSION_MINOR 11
Ben Cheng654325d2012-03-07 21:13:49 -080023/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -070024#define KGSL_CONTEXT_SAVE_GMEM 0x00000001
25#define KGSL_CONTEXT_NO_GMEM_ALLOC 0x00000002
26#define KGSL_CONTEXT_SUBMIT_IB_LIST 0x00000004
27#define KGSL_CONTEXT_CTX_SWITCH 0x00000008
28/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29#define KGSL_CONTEXT_PREAMBLE 0x00000010
30#define KGSL_CONTEXT_TRASH_STATE 0x00000020
31#define KGSL_CONTEXT_PER_CONTEXT_TS 0x00000040
32#define KGSL_CONTEXT_INVALID 0xffffffff
33/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34#define KGSL_MEMFLAGS_GPUREADONLY 0x01000000
Dima Zavin81fa6d52009-08-05 17:51:29 -070035#define KGSL_FLAGS_NORMALMODE 0x00000000
36#define KGSL_FLAGS_SAFEMODE 0x00000001
37#define KGSL_FLAGS_INITIALIZED0 0x00000002
Ben Cheng654325d2012-03-07 21:13:49 -080038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -070039#define KGSL_FLAGS_INITIALIZED 0x00000004
Dima Zavin81fa6d52009-08-05 17:51:29 -070040#define KGSL_FLAGS_STARTED 0x00000008
41#define KGSL_FLAGS_ACTIVE 0x00000010
42#define KGSL_FLAGS_RESERVED0 0x00000020
Naseer Ahmed240b3342012-06-18 14:54:42 -070043/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -070044#define KGSL_FLAGS_RESERVED1 0x00000040
45#define KGSL_FLAGS_RESERVED2 0x00000080
Naseer Ahmed240b3342012-06-18 14:54:42 -070046#define KGSL_FLAGS_SOFT_RESET 0x00000100
47#define KGSL_FLAGS_PER_CONTEXT_TIMESTAMPS 0x00000200
Ben Cheng654325d2012-03-07 21:13:49 -080048/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -070049#define KGSL_CLK_SRC 0x00000001
50#define KGSL_CLK_CORE 0x00000002
51#define KGSL_CLK_IFACE 0x00000004
52#define KGSL_CLK_MEM 0x00000008
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54#define KGSL_CLK_MEM_IFACE 0x00000010
55#define KGSL_CLK_AXI 0x00000020
56enum kgsl_ctx_reset_stat {
57 KGSL_CTX_STAT_NO_ERROR = 0x00000000,
58/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59 KGSL_CTX_STAT_GUILTY_CONTEXT_RESET_EXT = 0x00000001,
60 KGSL_CTX_STAT_INNOCENT_CONTEXT_RESET_EXT = 0x00000002,
61 KGSL_CTX_STAT_UNKNOWN_CONTEXT_RESET_EXT = 0x00000003
62};
63/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64#define KGSL_MAX_PWRLEVELS 5
65#define KGSL_CONVERT_TO_MBPS(val) (val*1000*1000U)
66enum kgsl_deviceid {
67 KGSL_DEVICE_3D0 = 0x00000000,
68/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69 KGSL_DEVICE_2D0 = 0x00000001,
70 KGSL_DEVICE_2D1 = 0x00000002,
71 KGSL_DEVICE_MAX = 0x00000003
72};
73/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74enum kgsl_user_mem_type {
75 KGSL_USER_MEM_TYPE_PMEM = 0x00000000,
76 KGSL_USER_MEM_TYPE_ASHMEM = 0x00000001,
77 KGSL_USER_MEM_TYPE_ADDR = 0x00000002,
78/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79 KGSL_USER_MEM_TYPE_ION = 0x00000003,
80 KGSL_USER_MEM_TYPE_MAX = 0x00000004,
Dima Zavin81fa6d52009-08-05 17:51:29 -070081};
Dima Zavin81fa6d52009-08-05 17:51:29 -070082struct kgsl_devinfo {
Ben Cheng654325d2012-03-07 21:13:49 -080083/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -070084 unsigned int device_id;
Dima Zavin81fa6d52009-08-05 17:51:29 -070085 unsigned int chip_id;
86 unsigned int mmu_enabled;
87 unsigned int gmem_gpubaseaddr;
Ben Cheng654325d2012-03-07 21:13:49 -080088/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -070089 unsigned int gpu_id;
Dima Zavin81fa6d52009-08-05 17:51:29 -070090 unsigned int gmem_sizebytes;
91};
Dima Zavin81fa6d52009-08-05 17:51:29 -070092struct kgsl_devmemstore {
Ben Cheng654325d2012-03-07 21:13:49 -080093/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -070094 volatile unsigned int soptimestamp;
95 unsigned int sbz;
96 volatile unsigned int eoptimestamp;
97 unsigned int sbz2;
Ben Cheng654325d2012-03-07 21:13:49 -080098/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin4e383b82010-03-08 17:34:52 -080099 volatile unsigned int ts_cmp_enable;
100 unsigned int sbz3;
101 volatile unsigned int ref_wait_ts;
102 unsigned int sbz4;
Ben Cheng654325d2012-03-07 21:13:49 -0800103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700104 unsigned int current_context;
105 unsigned int sbz5;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700106};
Naseer Ahmed240b3342012-06-18 14:54:42 -0700107#define KGSL_MEMSTORE_OFFSET(ctxt_id, field) ((ctxt_id)*sizeof(struct kgsl_devmemstore) + offsetof(struct kgsl_devmemstore, field))
108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700109enum kgsl_timestamp_type {
110 KGSL_TIMESTAMP_CONSUMED = 0x00000001,
111 KGSL_TIMESTAMP_RETIRED = 0x00000002,
Naseer Ahmed240b3342012-06-18 14:54:42 -0700112 KGSL_TIMESTAMP_QUEUED = 0x00000003,
113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700114};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700115enum kgsl_property_type {
116 KGSL_PROP_DEVICE_INFO = 0x00000001,
117 KGSL_PROP_DEVICE_SHADOW = 0x00000002,
Naseer Ahmed240b3342012-06-18 14:54:42 -0700118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700119 KGSL_PROP_DEVICE_POWER = 0x00000003,
120 KGSL_PROP_SHMEM = 0x00000004,
121 KGSL_PROP_SHMEM_APERTURES = 0x00000005,
Dima Zavin4e383b82010-03-08 17:34:52 -0800122 KGSL_PROP_MMU_ENABLE = 0x00000006,
Ben Cheng654325d2012-03-07 21:13:49 -0800123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700124 KGSL_PROP_INTERRUPT_WAITS = 0x00000007,
125 KGSL_PROP_VERSION = 0x00000008,
126 KGSL_PROP_GPU_RESET_STAT = 0x00000009,
127 KGSL_PROP_PWRCTRL = 0x0000000E,
128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
129};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700130struct kgsl_shadowprop {
131 unsigned int gpuaddr;
132 unsigned int size;
Ben Cheng654325d2012-03-07 21:13:49 -0800133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700134 unsigned int flags;
135};
136struct kgsl_pwrlevel {
137 unsigned int gpu_freq;
138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
139 unsigned int bus_freq;
140 unsigned int io_fraction;
141};
142struct kgsl_version {
143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
144 unsigned int drv_major;
145 unsigned int drv_minor;
146 unsigned int dev_major;
147 unsigned int dev_minor;
148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
149};
150struct kgsl_ibdesc {
151 unsigned int gpuaddr;
152 void *hostptr;
153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
154 unsigned int sizedwords;
155 unsigned int ctrl;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700156};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700157#define KGSL_IOC_TYPE 0x09
Naseer Ahmed240b3342012-06-18 14:54:42 -0700158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700159struct kgsl_device_getproperty {
160 unsigned int type;
161 void *value;
162 unsigned int sizebytes;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700164};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700165#define IOCTL_KGSL_DEVICE_GETPROPERTY _IOWR(KGSL_IOC_TYPE, 0x2, struct kgsl_device_getproperty)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700166struct kgsl_device_waittimestamp {
167 unsigned int timestamp;
Ben Cheng654325d2012-03-07 21:13:49 -0800168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700169 unsigned int timeout;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700170};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700171#define IOCTL_KGSL_DEVICE_WAITTIMESTAMP _IOW(KGSL_IOC_TYPE, 0x6, struct kgsl_device_waittimestamp)
Naseer Ahmed240b3342012-06-18 14:54:42 -0700172struct kgsl_device_waittimestamp_ctxtid {
173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
174 unsigned int context_id;
175 unsigned int timestamp;
176 unsigned int timeout;
177};
178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
179#define IOCTL_KGSL_DEVICE_WAITTIMESTAMP_CTXTID _IOW(KGSL_IOC_TYPE, 0x7, struct kgsl_device_waittimestamp_ctxtid)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700180struct kgsl_ringbuffer_issueibcmds {
181 unsigned int drawctxt_id;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700182 unsigned int ibdesc_addr;
Ben Cheng654325d2012-03-07 21:13:49 -0800183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700184 unsigned int numibs;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700185 unsigned int timestamp;
186 unsigned int flags;
187};
Naseer Ahmed240b3342012-06-18 14:54:42 -0700188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700189#define IOCTL_KGSL_RINGBUFFER_ISSUEIBCMDS _IOWR(KGSL_IOC_TYPE, 0x10, struct kgsl_ringbuffer_issueibcmds)
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700190struct kgsl_cmdstream_readtimestamp {
Dima Zavin81fa6d52009-08-05 17:51:29 -0700191 unsigned int type;
192 unsigned int timestamp;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700194};
Naseer Ahmed240b3342012-06-18 14:54:42 -0700195#define IOCTL_KGSL_CMDSTREAM_READTIMESTAMP_OLD _IOR(KGSL_IOC_TYPE, 0x11, struct kgsl_cmdstream_readtimestamp)
196#define IOCTL_KGSL_CMDSTREAM_READTIMESTAMP _IOWR(KGSL_IOC_TYPE, 0x11, struct kgsl_cmdstream_readtimestamp)
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700197struct kgsl_cmdstream_freememontimestamp {
Ben Cheng654325d2012-03-07 21:13:49 -0800198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700199 unsigned int gpuaddr;
200 unsigned int type;
201 unsigned int timestamp;
202};
Ben Cheng654325d2012-03-07 21:13:49 -0800203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700204#define IOCTL_KGSL_CMDSTREAM_FREEMEMONTIMESTAMP _IOW(KGSL_IOC_TYPE, 0x12, struct kgsl_cmdstream_freememontimestamp)
205#define IOCTL_KGSL_CMDSTREAM_FREEMEMONTIMESTAMP_OLD _IOR(KGSL_IOC_TYPE, 0x12, struct kgsl_cmdstream_freememontimestamp)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700206struct kgsl_drawctxt_create {
207 unsigned int flags;
Ben Cheng654325d2012-03-07 21:13:49 -0800208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700209 unsigned int drawctxt_id;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700210};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700211#define IOCTL_KGSL_DRAWCTXT_CREATE _IOWR(KGSL_IOC_TYPE, 0x13, struct kgsl_drawctxt_create)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700212struct kgsl_drawctxt_destroy {
Ben Cheng654325d2012-03-07 21:13:49 -0800213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Naseer Ahmed240b3342012-06-18 14:54:42 -0700214 unsigned int drawctxt_id;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700215};
Dima Zavin81fa6d52009-08-05 17:51:29 -0700216#define IOCTL_KGSL_DRAWCTXT_DESTROY _IOW(KGSL_IOC_TYPE, 0x14, struct kgsl_drawctxt_destroy)
Naseer Ahmed240b3342012-06-18 14:54:42 -0700217struct kgsl_map_user_mem {
218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
219 int fd;
220 unsigned int gpuaddr;
221 unsigned int len;
222 unsigned int offset;
223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
224 unsigned int hostptr;
225 enum kgsl_user_mem_type memtype;
226 unsigned int reserved;
227};
228/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
229#define IOCTL_KGSL_MAP_USER_MEM _IOWR(KGSL_IOC_TYPE, 0x15, struct kgsl_map_user_mem)
230struct kgsl_cmdstream_readtimestamp_ctxtid {
231 unsigned int context_id;
232 unsigned int type;
233/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
234 unsigned int timestamp;
235};
236#define IOCTL_KGSL_CMDSTREAM_READTIMESTAMP_CTXTID _IOWR(KGSL_IOC_TYPE, 0x16, struct kgsl_cmdstream_readtimestamp_ctxtid)
237struct kgsl_cmdstream_freememontimestamp_ctxtid {
238/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
239 unsigned int context_id;
240 unsigned int gpuaddr;
241 unsigned int type;
242 unsigned int timestamp;
243/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
244};
245#define IOCTL_KGSL_CMDSTREAM_FREEMEMONTIMESTAMP_CTXTID _IOW(KGSL_IOC_TYPE, 0x17, struct kgsl_cmdstream_freememontimestamp_ctxtid)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700246struct kgsl_sharedmem_from_pmem {
247 int pmem_fd;
Ben Cheng654325d2012-03-07 21:13:49 -0800248/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700249 unsigned int gpuaddr;
Dima Zavin7b12b4a2009-11-19 09:55:56 -0800250 unsigned int len;
251 unsigned int offset;
Dima Zavin81fa6d52009-08-05 17:51:29 -0700252};
Ben Cheng654325d2012-03-07 21:13:49 -0800253/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700254#define IOCTL_KGSL_SHAREDMEM_FROM_PMEM _IOWR(KGSL_IOC_TYPE, 0x20, struct kgsl_sharedmem_from_pmem)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700255struct kgsl_sharedmem_free {
256 unsigned int gpuaddr;
257};
Ben Cheng654325d2012-03-07 21:13:49 -0800258/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin81fa6d52009-08-05 17:51:29 -0700259#define IOCTL_KGSL_SHAREDMEM_FREE _IOW(KGSL_IOC_TYPE, 0x21, struct kgsl_sharedmem_free)
Naseer Ahmed240b3342012-06-18 14:54:42 -0700260struct kgsl_cff_user_event {
261 unsigned char cff_opcode;
262 unsigned int op1;
263/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
264 unsigned int op2;
265 unsigned int op3;
266 unsigned int op4;
267 unsigned int op5;
268/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
269 unsigned int __pad[2];
270};
271#define IOCTL_KGSL_CFF_USER_EVENT _IOW(KGSL_IOC_TYPE, 0x31, struct kgsl_cff_user_event)
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700272struct kgsl_gmem_desc {
Naseer Ahmed240b3342012-06-18 14:54:42 -0700273/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700274 unsigned int x;
275 unsigned int y;
276 unsigned int width;
277 unsigned int height;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700278/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700279 unsigned int pitch;
280};
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700281struct kgsl_buffer_desc {
282 void *hostptr;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700283/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700284 unsigned int gpuaddr;
285 int size;
286 unsigned int format;
287 unsigned int pitch;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700288/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700289 unsigned int enabled;
290};
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700291struct kgsl_bind_gmem_shadow {
292 unsigned int drawctxt_id;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700293/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700294 struct kgsl_gmem_desc gmem_desc;
295 unsigned int shadow_x;
296 unsigned int shadow_y;
297 struct kgsl_buffer_desc shadow_buffer;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700298/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700299 unsigned int buffer_id;
300};
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700301#define IOCTL_KGSL_DRAWCTXT_BIND_GMEM_SHADOW _IOW(KGSL_IOC_TYPE, 0x22, struct kgsl_bind_gmem_shadow)
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700302struct kgsl_sharedmem_from_vmalloc {
Naseer Ahmed240b3342012-06-18 14:54:42 -0700303/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700304 unsigned int gpuaddr;
305 unsigned int hostptr;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700306 unsigned int flags;
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700307};
Naseer Ahmed240b3342012-06-18 14:54:42 -0700308/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700309#define IOCTL_KGSL_SHAREDMEM_FROM_VMALLOC _IOWR(KGSL_IOC_TYPE, 0x23, struct kgsl_sharedmem_from_vmalloc)
Dima Zavin9a96aaa2009-10-03 16:38:49 -0700310#define IOCTL_KGSL_SHAREDMEM_FLUSH_CACHE _IOW(KGSL_IOC_TYPE, 0x24, struct kgsl_sharedmem_free)
Dima Zavin110044b2009-11-13 02:29:17 -0800311struct kgsl_drawctxt_set_bin_base_offset {
312 unsigned int drawctxt_id;
Naseer Ahmed240b3342012-06-18 14:54:42 -0700313/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Dima Zavin110044b2009-11-13 02:29:17 -0800314 unsigned int offset;
315};
Dima Zavin110044b2009-11-13 02:29:17 -0800316#define IOCTL_KGSL_DRAWCTXT_SET_BIN_BASE_OFFSET _IOW(KGSL_IOC_TYPE, 0x25, struct kgsl_drawctxt_set_bin_base_offset)
Naseer Ahmed240b3342012-06-18 14:54:42 -0700317enum kgsl_cmdwindow_type {
318/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
319 KGSL_CMDWINDOW_MIN = 0x00000000,
320 KGSL_CMDWINDOW_2D = 0x00000000,
321 KGSL_CMDWINDOW_3D = 0x00000001,
322 KGSL_CMDWINDOW_MMU = 0x00000002,
323/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
324 KGSL_CMDWINDOW_ARBITER = 0x000000FF,
325 KGSL_CMDWINDOW_MAX = 0x000000FF,
326};
327struct kgsl_cmdwindow_write {
328/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
329 enum kgsl_cmdwindow_type target;
330 unsigned int addr;
331 unsigned int data;
332};
333/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
334#define IOCTL_KGSL_CMDWINDOW_WRITE _IOW(KGSL_IOC_TYPE, 0x2e, struct kgsl_cmdwindow_write)
335struct kgsl_gpumem_alloc {
336 unsigned long gpuaddr;
337 size_t size;
338/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
339 unsigned int flags;
340};
341#define IOCTL_KGSL_GPUMEM_ALLOC _IOWR(KGSL_IOC_TYPE, 0x2f, struct kgsl_gpumem_alloc)
342struct kgsl_cff_syncmem {
343/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
344 unsigned int gpuaddr;
345 unsigned int len;
346 unsigned int __pad[2];
347};
348/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
349#define IOCTL_KGSL_CFF_SYNCMEM _IOW(KGSL_IOC_TYPE, 0x30, struct kgsl_cff_syncmem)
350struct kgsl_timestamp_event {
351 int type;
352 unsigned int timestamp;
353/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
354 unsigned int context_id;
355 void *priv;
356 size_t len;
357};
358/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
359#define IOCTL_KGSL_TIMESTAMP_EVENT _IOW(KGSL_IOC_TYPE, 0x31, struct kgsl_timestamp_event)
360#define KGSL_TIMESTAMP_EVENT_GENLOCK 1
361struct kgsl_timestamp_event_genlock {
362 int handle;
363/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
364};
365#define IOCTL_KGSL_SETPROPERTY _IOW(KGSL_IOC_TYPE, 0x32, struct kgsl_device_getproperty)
Dima Zavin81fa6d52009-08-05 17:51:29 -0700366#endif