mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 12:17:12 +09:00
rk30:add lcd_b101ew05 driver support from rk29
This commit is contained in:
@@ -66,6 +66,8 @@ config LCD_TX23D88VM
|
||||
bool "HITACHI LVDS TX23D88VM (1200x800)"
|
||||
config LCD_A050VL01
|
||||
bool "RGB A050VL01"
|
||||
config LCD_B101EW05
|
||||
bool "RGB lcd panel B101EW05"
|
||||
endchoice
|
||||
|
||||
|
||||
|
||||
@@ -34,3 +34,4 @@ obj-$(CONFIG_LCD_AT070TNA2) += lcd_AT070TNA2.o
|
||||
obj-$(CONFIG_LCD_TX23D88VM) += lcd_tx23d88vm.o
|
||||
obj-$(CONFIG_LCD_AT070TN93) += lcd_at070tn93.o
|
||||
obj-$(CONFIG_LCD_A050VL01) += lcd_A050VL01.o
|
||||
obj-$(CONFIG_LCD_B101EW05) += lcd_b101ew05.o
|
||||
|
||||
76
drivers/video/display/screen/lcd_b101ew05.c
Executable file
76
drivers/video/display/screen/lcd_b101ew05.c
Executable file
@@ -0,0 +1,76 @@
|
||||
#include <linux/fb.h>
|
||||
#include <linux/delay.h>
|
||||
#include "../../rk29_fb.h"
|
||||
#include <mach/gpio.h>
|
||||
#include <mach/iomux.h>
|
||||
#include <mach/board.h>
|
||||
#include "screen.h"
|
||||
|
||||
|
||||
/* Base */
|
||||
#define OUT_TYPE SCREEN_RGB
|
||||
|
||||
#define OUT_FACE OUT_D888_P666
|
||||
|
||||
|
||||
#define OUT_CLK 75000000
|
||||
#define LCDC_ACLK 800000000 //29 lcdc axi DMA Ƶ<><C6B5>
|
||||
|
||||
/* Timing */
|
||||
#define H_PW 10
|
||||
#define H_BP 100
|
||||
#define H_VD 1280
|
||||
#define H_FP 58
|
||||
|
||||
#define V_PW 2
|
||||
#define V_BP 8
|
||||
#define V_VD 800
|
||||
#define V_FP 6
|
||||
|
||||
#define LCD_WIDTH 216
|
||||
#define LCD_HEIGHT 135
|
||||
/* Other */
|
||||
#define DCLK_POL 0
|
||||
#define SWAP_RB 0
|
||||
|
||||
|
||||
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 = NULL;
|
||||
screen->standby = NULL;
|
||||
}
|
||||
Reference in New Issue
Block a user