tegrafb.h revision a7f976c9de3c20cc8cdde4f3dfeeb48a1a89adb7
1/****************************************************************************
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 ****************************************************************************
11 ****************************************************************************/
12#ifndef _LINUX_TEGRAFB_H_
13#define _LINUX_TEGRAFB_H_
14
15#include <linux/fb.h>
16#include <linux/types.h>
17#include <asm/ioctl.h>
18
19#define TEGRA_FB_WIN_FMT_P1 0
20#define TEGRA_FB_WIN_FMT_P2 1
21#define TEGRA_FB_WIN_FMT_P4 2
22#define TEGRA_FB_WIN_FMT_P8 3
23#define TEGRA_FB_WIN_FMT_B4G4R4A4 4
24#define TEGRA_FB_WIN_FMT_B5G5R5A 5
25#define TEGRA_FB_WIN_FMT_B5G6R5 6
26#define TEGRA_FB_WIN_FMT_AB5G5R5 7
27#define TEGRA_FB_WIN_FMT_B8G8R8A8 12
28#define TEGRA_FB_WIN_FMT_R8G8B8A8 13
29#define TEGRA_FB_WIN_FMT_B6x2G6x2R6x2A8 14
30#define TEGRA_FB_WIN_FMT_R6x2G6x2B6x2A8 15
31#define TEGRA_FB_WIN_FMT_YCbCr422 16
32#define TEGRA_FB_WIN_FMT_YUV422 17
33#define TEGRA_FB_WIN_FMT_YCbCr420P 18
34#define TEGRA_FB_WIN_FMT_YUV420P 19
35#define TEGRA_FB_WIN_FMT_YCbCr422P 20
36#define TEGRA_FB_WIN_FMT_YUV422P 21
37#define TEGRA_FB_WIN_FMT_YCbCr422R 22
38#define TEGRA_FB_WIN_FMT_YUV422R 23
39#define TEGRA_FB_WIN_FMT_YCbCr422RA 24
40#define TEGRA_FB_WIN_FMT_YUV422RA 25
41
42#define TEGRA_FB_WIN_BLEND_NONE 0
43#define TEGRA_FB_WIN_BLEND_PREMULT 1
44#define TEGRA_FB_WIN_BLEND_COVERAGE 2
45
46#define TEGRA_FB_WIN_FLAG_INVERT_H (1<<0)
47#define TEGRA_FB_WIN_FLAG_INVERT_V (1<<1)
48#define TEGRA_FB_WIN_FLAG_TILED (1<<2)
49
50struct tegra_fb_windowattr {
51 __s32 index;
52 __u32 buff_id;
53 __u32 flags;
54 __u32 blend;
55 __u32 offset;
56 __u32 offset_u;
57 __u32 offset_v;
58 __u32 stride;
59 __u32 stride_uv;
60 __u32 pixformat;
61 __u32 x;
62 __u32 y;
63 __u32 w;
64 __u32 h;
65 __u32 out_x;
66 __u32 out_y;
67 __u32 out_w;
68 __u32 out_h;
69 __u32 z;
70 __u32 pre_syncpt_id;
71 __u32 pre_syncpt_val;
72};
73
74#define TEGRA_FB_FLIP_N_WINDOWS 3
75
76struct tegra_fb_flip_args {
77 struct tegra_fb_windowattr win[TEGRA_FB_FLIP_N_WINDOWS];
78 __u32 post_syncpt_id;
79 __u32 post_syncpt_val;
80};
81
82struct tegra_fb_modedb {
83 struct fb_var_screeninfo *modedb;
84 __u32 modedb_len;
85};
86
87#define FBIO_TEGRA_SET_NVMAP_FD _IOW('F', 0x40, __u32)
88#define FBIO_TEGRA_FLIP _IOW('F', 0x41, struct tegra_fb_flip_args)
89#define FBIO_TEGRA_GET_MODEDB _IOWR('F', 0x42, struct tegra_fb_modedb)
90
91#endif
92
93