From bb754595de10d0ab588ec1ff2c075077cc181ac1 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 9 Mar 2011 16:27:27 +0800 Subject: [PATCH] In video mode change to PIXEL_FORMAT_RGB_565 --- drivers/video/rk29_fb.c | 7 +++++-- include/linux/fb.h | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/video/rk29_fb.c b/drivers/video/rk29_fb.c index 08ed5bc01f85..f4a6432ee698 100755 --- a/drivers/video/rk29_fb.c +++ b/drivers/video/rk29_fb.c @@ -469,7 +469,7 @@ int init_lcdc(struct fb_info *info) // set AHB access rule and disable all windows LcdWrReg(inf, SYS_CONFIG, 0x60000000); LcdWrReg(inf, SWAP_CTRL, 0); - LcdWrReg(inf, FIFO_WATER_MARK, 0x00000864);//68 + LcdWrReg(inf, FIFO_WATER_MARK, 0x00000862);//68 LcdWrReg(inf, AXI_MS_ID, 0x54321); // and mcu holdmode; and set win1 top. @@ -1452,6 +1452,9 @@ static int fb0_ioctl(struct fb_info *info, unsigned int cmd, unsigned long arg) break; case FBIOPUT_FBPHYADD: return info->fix.smem_start; + case FBIOGET_OVERLAY_STATE: + return inf->video_mode; + case FBIOPUT_SET_CURSOR_EN: { int en; @@ -1777,7 +1780,7 @@ int fb1_open(struct fb_info *info, int user) par->addr_seted = 0; inf->video_mode = 1; wq_condition2 = 1; - + memset(inf->fb0->screen_base, 0, inf->fb0->fix.smem_len); if(par->refcount) { printk(">>>>>> fb1 has opened! \n"); return -EACCES; diff --git a/include/linux/fb.h b/include/linux/fb.h index 54ce1d9883b6..74595389f4ef 100755 --- a/include/linux/fb.h +++ b/include/linux/fb.h @@ -26,6 +26,7 @@ struct dentry; #define FBIOPUT_SET_CURSOR_CMAP 0x460c #define FBIOPUT_GET_CURSOR_RESOLUTION 0x460d #define FBIOPUT_GET_CURSOR_EN 0x460e +#define FBIOGET_OVERLAY_STATE 0X460f #ifdef __KERNEL__ #define FBIO_CURSOR _IOWR('F', 0x08, struct fb_cursor_user) #else -- 2.34.1