Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
exynos_drm.h
Go to the documentation of this file.
1 /* exynos_drm.h
2  *
3  * Copyright (c) 2011 Samsung Electronics Co., Ltd.
4  * Authors:
5  * Inki Dae <[email protected]>
6  * Joonyoung Shim <[email protected]>
7  * Seung-Woo Kim <[email protected]>
8  *
9  * Permission is hereby granted, free of charge, to any person obtaining a
10  * copy of this software and associated documentation files (the "Software"),
11  * to deal in the Software without restriction, including without limitation
12  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
13  * and/or sell copies of the Software, and to permit persons to whom the
14  * Software is furnished to do so, subject to the following conditions:
15  *
16  * The above copyright notice and this permission notice (including the next
17  * paragraph) shall be included in all copies or substantial portions of the
18  * Software.
19  *
20  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
23  * VA LINUX SYSTEMS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
24  * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
25  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
26  * OTHER DEALINGS IN THE SOFTWARE.
27  */
28 
29 #ifndef _UAPI_EXYNOS_DRM_H_
30 #define _UAPI_EXYNOS_DRM_H_
31 
32 #include <drm/drm.h>
33 
45  unsigned int flags;
46  unsigned int handle;
47 };
48 
58  unsigned int handle;
59  unsigned int pad;
61 };
62 
75  unsigned int handle;
76  unsigned int pad;
79 };
80 
91  unsigned int handle;
92  unsigned int flags;
94 };
95 
105  unsigned int connection;
106  unsigned int extensions;
108 };
109 
110 /* memory type definitions. */
112  /* Physically Continuous memory and used as default. */
114  /* Physically Non-Continuous memory. */
116  /* non-cachable mapping and used as default. */
118  /* cachable mapping. */
120  /* write-combine mapping. */
121  EXYNOS_BO_WC = 1 << 2,
124 };
125 
129 };
130 
134 };
135 
139  G2D_EVENT_STOP, /* not yet */
140 };
141 
147 
148  /* for g2d event */
151 };
152 
155 };
156 
157 #define DRM_EXYNOS_GEM_CREATE 0x00
158 #define DRM_EXYNOS_GEM_MAP_OFFSET 0x01
159 #define DRM_EXYNOS_GEM_MMAP 0x02
160 /* Reserved 0x03 ~ 0x05 for exynos specific gem ioctl */
161 #define DRM_EXYNOS_GEM_GET 0x04
162 #define DRM_EXYNOS_VIDI_CONNECTION 0x07
163 
164 /* G2D */
165 #define DRM_EXYNOS_G2D_GET_VER 0x20
166 #define DRM_EXYNOS_G2D_SET_CMDLIST 0x21
167 #define DRM_EXYNOS_G2D_EXEC 0x22
168 
169 #define DRM_IOCTL_EXYNOS_GEM_CREATE DRM_IOWR(DRM_COMMAND_BASE + \
170  DRM_EXYNOS_GEM_CREATE, struct drm_exynos_gem_create)
171 
172 #define DRM_IOCTL_EXYNOS_GEM_MAP_OFFSET DRM_IOWR(DRM_COMMAND_BASE + \
173  DRM_EXYNOS_GEM_MAP_OFFSET, struct drm_exynos_gem_map_off)
174 
175 #define DRM_IOCTL_EXYNOS_GEM_MMAP DRM_IOWR(DRM_COMMAND_BASE + \
176  DRM_EXYNOS_GEM_MMAP, struct drm_exynos_gem_mmap)
177 
178 #define DRM_IOCTL_EXYNOS_GEM_GET DRM_IOWR(DRM_COMMAND_BASE + \
179  DRM_EXYNOS_GEM_GET, struct drm_exynos_gem_info)
180 
181 #define DRM_IOCTL_EXYNOS_VIDI_CONNECTION DRM_IOWR(DRM_COMMAND_BASE + \
182  DRM_EXYNOS_VIDI_CONNECTION, struct drm_exynos_vidi_connection)
183 
184 #define DRM_IOCTL_EXYNOS_G2D_GET_VER DRM_IOWR(DRM_COMMAND_BASE + \
185  DRM_EXYNOS_G2D_GET_VER, struct drm_exynos_g2d_get_ver)
186 #define DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST DRM_IOWR(DRM_COMMAND_BASE + \
187  DRM_EXYNOS_G2D_SET_CMDLIST, struct drm_exynos_g2d_set_cmdlist)
188 #define DRM_IOCTL_EXYNOS_G2D_EXEC DRM_IOWR(DRM_COMMAND_BASE + \
189  DRM_EXYNOS_G2D_EXEC, struct drm_exynos_g2d_exec)
190 
191 /* EXYNOS specific events */
192 #define DRM_EXYNOS_G2D_EVENT 0x80000000
193 
195  struct drm_event base;
201 };
202 
203 #endif /* _UAPI_EXYNOS_DRM_H_ */