aboutsummaryrefslogtreecommitdiffstats
path: root/exynos
diff options
context:
space:
mode:
authorTobias Jakobi2015-09-08 10:22:34 -0500
committerEmil Velikov2015-09-21 11:43:14 -0500
commitdf21b293e9cf550ec8d6a3e49461350dbdf14260 (patch)
treedea79a95892fe72c6350be75a11027446a44f8ef /exynos
parentce4a4f6e21d4112f0b88c973283b586e1fccddd9 (diff)
downloadexternal-libdrm-df21b293e9cf550ec8d6a3e49461350dbdf14260.tar.gz
external-libdrm-df21b293e9cf550ec8d6a3e49461350dbdf14260.tar.xz
external-libdrm-df21b293e9cf550ec8d6a3e49461350dbdf14260.zip
exynos/fimg2d: remove g2d_context from public header
All functions from the public API only operation on struct g2d_context*, so this shouldn't break too much. Make the context private since we don't want the user to modify its content directly. Also remove the defines that were only used for fields of g2d_context. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de>
Diffstat (limited to 'exynos')
-rw-r--r--exynos/exynos_fimg2d.c15
-rw-r--r--exynos/exynos_fimg2d.h14
2 files changed, 16 insertions, 13 deletions
diff --git a/exynos/exynos_fimg2d.c b/exynos/exynos_fimg2d.c
index 9746c213..e7341449 100644
--- a/exynos/exynos_fimg2d.c
+++ b/exynos/exynos_fimg2d.c
@@ -44,6 +44,21 @@
44 44
45#define MSG_PREFIX "exynos/fimg2d: " 45#define MSG_PREFIX "exynos/fimg2d: "
46 46
47#define G2D_MAX_CMD_NR 64
48#define G2D_MAX_GEM_CMD_NR 64
49#define G2D_MAX_CMD_LIST_NR 64
50
51struct g2d_context {
52 int fd;
53 unsigned int major;
54 unsigned int minor;
55 struct drm_exynos_g2d_cmd cmd[G2D_MAX_CMD_NR];
56 struct drm_exynos_g2d_cmd cmd_buf[G2D_MAX_GEM_CMD_NR];
57 unsigned int cmd_nr;
58 unsigned int cmd_buf_nr;
59 unsigned int cmdlist_nr;
60};
61
47enum g2d_base_addr_reg { 62enum g2d_base_addr_reg {
48 g2d_dst = 0, 63 g2d_dst = 0,
49 g2d_src 64 g2d_src
diff --git a/exynos/exynos_fimg2d.h b/exynos/exynos_fimg2d.h
index 9db0c88b..4aa15683 100644
--- a/exynos/exynos_fimg2d.h
+++ b/exynos/exynos_fimg2d.h
@@ -13,9 +13,6 @@
13#ifndef _FIMG2D_H_ 13#ifndef _FIMG2D_H_
14#define _FIMG2D_H_ 14#define _FIMG2D_H_
15 15
16#define G2D_MAX_CMD_NR 64
17#define G2D_MAX_GEM_CMD_NR 64
18#define G2D_MAX_CMD_LIST_NR 64
19#define G2D_PLANE_MAX_NR 2 16#define G2D_PLANE_MAX_NR 2
20 17
21enum e_g2d_color_mode { 18enum e_g2d_color_mode {
@@ -289,16 +286,7 @@ struct g2d_image {
289 void *mapped_ptr[G2D_PLANE_MAX_NR]; 286 void *mapped_ptr[G2D_PLANE_MAX_NR];
290}; 287};
291 288
292struct g2d_context { 289struct g2d_context;
293 int fd;
294 unsigned int major;
295 unsigned int minor;
296 struct drm_exynos_g2d_cmd cmd[G2D_MAX_CMD_NR];
297 struct drm_exynos_g2d_cmd cmd_buf[G2D_MAX_GEM_CMD_NR];
298 unsigned int cmd_nr;
299 unsigned int cmd_buf_nr;
300 unsigned int cmdlist_nr;
301};
302 290
303struct g2d_context *g2d_init(int fd); 291struct g2d_context *g2d_init(int fd);
304void g2d_fini(struct g2d_context *ctx); 292void g2d_fini(struct g2d_context *ctx);