diff options
author | Andy Voltz <andy.voltz@timesys.com> | 2012-11-16 17:35:03 -0500 |
---|---|---|
committer | Andy Voltz <andy.voltz@timesys.com> | 2012-11-20 10:16:27 -0500 |
commit | 1908e12958738f62fd0f94c7677805e2f98efb32 (patch) | |
tree | 6512ae1370a730a90b6986cd0a593a9384d70b2e | |
parent | 3fccd19ab025096259cd70364e05ce183a31bf21 (diff) |
mvf-dcu: Move ioctls to public header
-rw-r--r-- | arch/arm/plat-mxc/include/mach/mvf-dcu-fb.h | 52 | ||||
-rw-r--r-- | include/linux/Kbuild | 1 | ||||
-rw-r--r-- | include/linux/mvf-fb.h | 74 |
3 files changed, 76 insertions, 51 deletions
diff --git a/arch/arm/plat-mxc/include/mach/mvf-dcu-fb.h b/arch/arm/plat-mxc/include/mach/mvf-dcu-fb.h index b9d8dd3b93bb..9a5ba8e396a9 100644 --- a/arch/arm/plat-mxc/include/mach/mvf-dcu-fb.h +++ b/arch/arm/plat-mxc/include/mach/mvf-dcu-fb.h @@ -14,6 +14,7 @@ #define __MVF_DCU_FB_H__ #include <linux/types.h> +#include <linux/mvf-fb.h> struct mvf_dcu_platform_data { char *mode_str; @@ -21,11 +22,6 @@ struct mvf_dcu_platform_data { int (*init) (int); }; -struct mfb_alpha { - int enable; - int alpha; -}; - struct dfb_chroma_key { int enable; __u8 red_max; @@ -36,60 +32,14 @@ struct dfb_chroma_key { __u8 blue_min; }; -struct layer_display_offset { - int x_layer_d; - int y_layer_d; -}; - #define DCU_LCD_ENABLE_PIN 30 #define MFB_SET_CHROMA_KEY _IOW('M', 1, struct mfb_chroma_key) #define MFB_SET_BRIGHTNESS _IOW('M', 3, __u8) -#define MFB_SET_ALPHA 0x80014d00 -#define MFB_GET_ALPHA 0x40014d00 -#define MFB_SET_LAYER 0x80084d04 -#define MFB_GET_LAYER 0x40084d04 - -#define FBIOGET_GWINFO 0x46E0 -#define FBIOPUT_GWINFO 0x46E1 - #ifdef __KERNEL__ #include <linux/spinlock.h> -/* - * These are the fields of control descriptor for every layer - */ -struct dcu_layer_desc { - u32 layer_num; - u32 width; - u32 height; - u32 posx; - u32 posy; - u32 addr; - u32 blend; - u32 chroma_key_en; - u32 lut_offset; - u32 rle_en; - u32 bpp; - u32 trans; - u32 safety_en; - u32 data_sel_clut; - u32 tile_en; - u32 en; - u32 ck_r_min; - u32 ck_r_max; - u32 ck_g_min; - u32 ck_g_max; - u32 ck_b_min; - u32 ck_b_max; - u32 tile_width; - u32 tile_height; - u32 trans_fgcolor; - u32 trans_bgcolor; -} __packed; - - /* DCU registers */ #define DCU_CTRLDESCCURSOR1 0x0000 #define DCU_CTRLDESCCURSOR1_HEIGHT(x) (x << 16) diff --git a/include/linux/Kbuild b/include/linux/Kbuild index c65d1b9eb546..947d36f054e5 100644 --- a/include/linux/Kbuild +++ b/include/linux/Kbuild @@ -35,6 +35,7 @@ header-y += mxc_si4702.h header-y += mxc_sim_interface.h header-y += mxc_v4l2.h header-y += mxcfb.h +header-y += mvf-fb.h header-y += pmic_adc.h header-y += pmic_battery.h header-y += pmic_external.h diff --git a/include/linux/mvf-fb.h b/include/linux/mvf-fb.h new file mode 100644 index 000000000000..836767697d76 --- /dev/null +++ b/include/linux/mvf-fb.h @@ -0,0 +1,74 @@ +/* + * Copyright 2012 Freescale Semiconductor, Inc. + * + * Freescale DCU Frame Buffer device driver ioctls + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + * + */ + +#ifndef __MVF_FB_H__ +#define __MVF_FB_H__ + +#include <linux/fb.h> + +/* ioctls */ + +#define MFB_SET_ALPHA 0x80014d00 +#define MFB_GET_ALPHA 0x40014d00 +#define MFB_SET_LAYER 0x80084d04 +#define MFB_GET_LAYER 0x40084d04 + +#define FBIOGET_GWINFO 0x46E0 +#define FBIOPUT_GWINFO 0x46E1 + +#ifndef u32 +#define u32 unsigned int +#endif + +struct mfb_alpha { + int enable; + int alpha; +}; + +struct layer_display_offset { + int x_layer_d; + int y_layer_d; +}; + +/* + * These are the fields of control descriptor for every layer + */ +struct dcu_layer_desc { + u32 layer_num; + u32 width; + u32 height; + u32 posx; + u32 posy; + u32 addr; + u32 blend; + u32 chroma_key_en; + u32 lut_offset; + u32 rle_en; + u32 bpp; + u32 trans; + u32 safety_en; + u32 data_sel_clut; + u32 tile_en; + u32 en; + u32 ck_r_min; + u32 ck_r_max; + u32 ck_g_min; + u32 ck_g_max; + u32 ck_b_min; + u32 ck_b_max; + u32 tile_width; + u32 tile_height; + u32 trans_fgcolor; + u32 trans_bgcolor; +} __packed; + +#endif |