From: yxj Date: Thu, 13 Sep 2012 06:16:08 +0000 (+0800) Subject: rk2928 A720 lcd :modify timing according the spec and rename the driver file name X-Git-Tag: firefly_0821_release~8631^2~16 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=522502ca00f19c23e2c2121b87d729c193620c84;p=firefly-linux-kernel-4.4.55.git rk2928 A720 lcd :modify timing according the spec and rename the driver file name --- diff --git a/drivers/video/display/screen/Makefile b/drivers/video/display/screen/Makefile index 57f551d2bbe0..a3ea521ecb44 100755 --- a/drivers/video/display/screen/Makefile +++ b/drivers/video/display/screen/Makefile @@ -42,5 +42,5 @@ obj-$(CONFIG_LCD_HJ050NA_06A) += lcd_hj050na_06a.o obj-$(CONFIG_LCD_HSD100PXN_FOR_TDW851) += lcd_hsd100pxn_for_tdw851.o obj-$(CONFIG_LCD_HV070WSA100) += lcd_hv070wsa.o obj-$(CONFIG_LCD_COMMON) += lcd_common.o -obj-$(CONFIG_LCD_RK2928_A720) += lcd_rk2928_a720.o -obj-$(CONFIG_LCD_HJ080NA) += lcd_hj080na.o \ No newline at end of file +obj-$(CONFIG_LCD_RK2928_A720) += lcd_YQ70CPT9160.o +obj-$(CONFIG_LCD_HJ080NA) += lcd_hj080na.o diff --git a/drivers/video/display/screen/lcd_YQ70CPT9160.c b/drivers/video/display/screen/lcd_YQ70CPT9160.c new file mode 100644 index 000000000000..dd080d6e2d9e --- /dev/null +++ b/drivers/video/display/screen/lcd_YQ70CPT9160.c @@ -0,0 +1,80 @@ +/* This Lcd Driver is HSD070IDW1 write by cst 2009.10.27 */ +#include +#include +#include "../../rk29_fb.h" +#include +#include +#include +#include "screen.h" + + +/* Base */ +#define OUT_TYPE SCREEN_RGB +#define OUT_FACE OUT_P666 +#define OUT_CLK 33000000 +#define LCDC_ACLK 150000000 //29 lcdc axi DMA ƵÂÊ + +/* Timing */ +#define H_PW 30//48 //10 +#define H_BP 10//40 //100 +#define H_VD 800 //1024 +#define H_FP 210// //210 + +#define V_PW 13//10 +#define V_BP 10// //10 +#define V_VD 480 //768 +#define V_FP 22 //18 + +/* Other */ +#define DCLK_POL 1 +#define SWAP_RB 0 + +#define LCD_WIDTH 154 //need modify +#define LCD_HEIGHT 85 + +static struct rk29lcd_info *gLcd_info = NULL; + +void set_lcd_info(struct rk29fb_screen *screen, struct rk29lcd_info *lcd_info ) +{ + /* screen type & face */ + screen->type = OUT_TYPE; + screen->face = OUT_FACE; + + /* Screen size */ + screen->x_res = H_VD; + screen->y_res = V_VD; + + screen->width = LCD_WIDTH; + screen->height = LCD_HEIGHT; + + /* Timing */ + screen->lcdc_aclk = LCDC_ACLK; + screen->pixclock = OUT_CLK; + screen->left_margin = H_BP; + screen->right_margin = H_FP; + screen->hsync_len = H_PW; + screen->upper_margin = V_BP; + screen->lower_margin = V_FP; + screen->vsync_len = V_PW; + + /* Pin polarity */ + screen->pin_hsync = 0; + screen->pin_vsync = 0; + screen->pin_den = 0; + screen->pin_dclk = DCLK_POL; + + /* Swap rule */ + screen->swap_rb = SWAP_RB; + screen->swap_rg = 0; + screen->swap_gb = 0; + screen->swap_delta = 0; + screen->swap_dumy = 0; + + /* Operation function*/ + /*screen->init = init;*/ + screen->init = NULL; + screen->standby = NULL; + if(lcd_info) + gLcd_info = lcd_info; +} + diff --git a/drivers/video/display/screen/lcd_rk2928_a720.c b/drivers/video/display/screen/lcd_rk2928_a720.c deleted file mode 100644 index 32dfd4d65ada..000000000000 --- a/drivers/video/display/screen/lcd_rk2928_a720.c +++ /dev/null @@ -1,80 +0,0 @@ -/* This Lcd Driver is HSD070IDW1 write by cst 2009.10.27 */ -#include -#include -#include "../../rk29_fb.h" -#include -#include -#include -#include "screen.h" - - -/* Base */ -#define OUT_TYPE SCREEN_RGB -#define OUT_FACE OUT_P666 -#define OUT_CLK 30000000 -#define LCDC_ACLK 150000000 //29 lcdc axi DMA ƵÂÊ - -/* Timing */ -#define H_PW 48 //10 -#define H_BP 40 //100 -#define H_VD 800 //1024 -#define H_FP 40 //210 - -#define V_PW 3 //10 -#define V_BP 29 //10 -#define V_VD 480 //768 -#define V_FP 13 //18 - -/* Other */ -#define DCLK_POL 1 -#define SWAP_RB 0 - -#define LCD_WIDTH 154 //need modify -#define LCD_HEIGHT 85 - -static struct rk29lcd_info *gLcd_info = NULL; - -void set_lcd_info(struct rk29fb_screen *screen, struct rk29lcd_info *lcd_info ) -{ - /* screen type & face */ - screen->type = OUT_TYPE; - screen->face = OUT_FACE; - - /* Screen size */ - screen->x_res = H_VD; - screen->y_res = V_VD; - - screen->width = LCD_WIDTH; - screen->height = LCD_HEIGHT; - - /* Timing */ - screen->lcdc_aclk = LCDC_ACLK; - screen->pixclock = OUT_CLK; - screen->left_margin = H_BP; - screen->right_margin = H_FP; - screen->hsync_len = H_PW; - screen->upper_margin = V_BP; - screen->lower_margin = V_FP; - screen->vsync_len = V_PW; - - /* Pin polarity */ - screen->pin_hsync = 0; - screen->pin_vsync = 0; - screen->pin_den = 0; - screen->pin_dclk = DCLK_POL; - - /* Swap rule */ - screen->swap_rb = SWAP_RB; - screen->swap_rg = 0; - screen->swap_gb = 0; - screen->swap_delta = 0; - screen->swap_dumy = 0; - - /* Operation function*/ - /*screen->init = init;*/ - screen->init = NULL; - screen->standby = NULL; - if(lcd_info) - gLcd_info = lcd_info; -} -