From 9a27d5916b1d0338f76a4a8cb6fabc5320664453 Mon Sep 17 00:00:00 2001 From: Guoqing Li Date: Fri, 13 Sep 2013 14:59:45 +0800 Subject: video: mmp: rb swap setting update for mmp display We could set rb swap in two modules: DMA controler input part and dsi interface output part. DMA input part is based on pix_fmt to set rbswap, dsi output interface part will set rbswap based on platform dsi_rbswap configuration. This patch include below change and enhancement: 1) The input format which support rbswap is based on RGB format, eg. RGB565 indicates the source data in memory is that Red is [15~11], Green is [10~5], Blue is [4:0], Red is MSB, Blue is LSB, but for the display dma input default setting(rbswap = 0), it only support Blue is [15~11], Green is [10~5], Red is [4:0], Red is LSB, Blue is MSB, so for this format(RGB565), display controller need to set rbswap = 1 and it can support the MSB/LSB correctly. BGR/YUV format will not set it in mmp display driver. 2) The dsi output part of rbswap is depend on dsi_rbswap which is defined in specific platfrom. For output dsi interface, it has this feature to do rbswap again if it needs specifc byte sequence of RGB byte for DSI panel. eg. If display content is set RGB565 in memory and DMA input part set rbswap in driver to support Red as MSB , Blue LSB, but dsi panel only support Red as LSB, Blue as MSB, then it can use this feature. If there is no this requirement of panel, this dsi output part is not needed. Signed-off-by: Guoqing Li Signed-off-by: Jett.Zhou Signed-off-by: Zhou Zhu Reviewed-by: Daniel Drake Signed-off-by: Tomi Valkeinen --- include/video/mmp_disp.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/video') diff --git a/include/video/mmp_disp.h b/include/video/mmp_disp.h index b9dd1fbb0082..32094c052deb 100644 --- a/include/video/mmp_disp.h +++ b/include/video/mmp_disp.h @@ -334,6 +334,7 @@ struct mmp_mach_path_config { int output_type; u32 path_config; u32 link_config; + u32 dsi_rbswap; }; struct mmp_mach_plat_info { -- cgit v1.2.3 From 24586d8342ab27bc75e4560d71e98f3e5dc67d8e Mon Sep 17 00:00:00 2001 From: Jing Xiang Date: Fri, 13 Sep 2013 14:59:49 +0800 Subject: video: mmp: add pitch info in mmp_win structure Add pitch length info of graphics/video layer, pitch is used to represent line length in byte, the usage depends on pix_fmt. If the fmt is YUV, the pitch[0] will be Y length,pitch[1] will be U length, pitch[2] will be V lenth. If the fmt is RGB, the picth[0] will be line lenth, and pitch[1]/pitch[2] will be 0 and not be used. Signed-off-by: Jing Xiang Signed-off-by: Jett.Zhou Signed-off-by: Zhou Zhu Reviewed-by: Daniel Drake Signed-off-by: Tomi Valkeinen --- include/video/mmp_disp.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/video') diff --git a/include/video/mmp_disp.h b/include/video/mmp_disp.h index 32094c052deb..9fd9398368d5 100644 --- a/include/video/mmp_disp.h +++ b/include/video/mmp_disp.h @@ -91,6 +91,11 @@ struct mmp_win { u16 up_crop; u16 bottom_crop; int pix_fmt; + /* + * pitch[0]: graphics/video layer line length or y pitch + * pitch[1]/pitch[2]: video u/v pitch if non-zero + */ + u32 pitch[3]; }; struct mmp_addr { -- cgit v1.2.3 From 8af2c2869fd129bce0d0dfd86c6364c1096f9eff Mon Sep 17 00:00:00 2001 From: Jean-Christophe PLAGNIOL-VILLARD Date: Thu, 28 Mar 2013 22:53:42 +0800 Subject: video: atmel_lcdfb: fix platform data struct Today we mix pdata and drivers data in the struct atmel_lcdfb_info Fix it and introduce a new struct atmel_lcdfb_pdata for platform data only Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD Signed-off-by: Tomi Valkeinen --- include/video/atmel_lcdc.h | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) (limited to 'include/video') diff --git a/include/video/atmel_lcdc.h b/include/video/atmel_lcdc.h index 0f5a2fc69af9..f197c54712b0 100644 --- a/include/video/atmel_lcdc.h +++ b/include/video/atmel_lcdc.h @@ -31,39 +31,18 @@ #define ATMEL_LCDC_WIRING_BGR 0 #define ATMEL_LCDC_WIRING_RGB 1 -struct atmel_lcdfb_config; /* LCD Controller info data structure, stored in device platform_data */ -struct atmel_lcdfb_info { - spinlock_t lock; - struct fb_info *info; - void __iomem *mmio; - int irq_base; - struct work_struct task; - +struct atmel_lcdfb_pdata { unsigned int guard_time; - unsigned int smem_len; - struct platform_device *pdev; - struct clk *bus_clk; - struct clk *lcdc_clk; - -#ifdef CONFIG_BACKLIGHT_ATMEL_LCDC - struct backlight_device *backlight; - u8 bl_power; -#endif bool lcdcon_is_backlight; bool lcdcon_pol_negative; - u8 saved_lcdcon; - u8 default_bpp; u8 lcd_wiring_mode; unsigned int default_lcdcon2; unsigned int default_dmacon; void (*atmel_lcdfb_power_control)(int on); struct fb_monspecs *default_monspecs; - u32 pseudo_palette[16]; - - struct atmel_lcdfb_config *config; }; #define ATMEL_LCDC_DMABADDR1 0x00 -- cgit v1.2.3 From ce3b64f5f1ba9126c7f97115c15abe9c322d24e1 Mon Sep 17 00:00:00 2001 From: Jean-Christophe PLAGNIOL-VILLARD Date: Fri, 29 Mar 2013 02:05:47 +0800 Subject: video: atmel_lcdfb: pass the pdata as params so we can use have list gpio as example (probe via DT) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD Signed-off-by: Tomi Valkeinen --- include/video/atmel_lcdc.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'include/video') diff --git a/include/video/atmel_lcdc.h b/include/video/atmel_lcdc.h index f197c54712b0..c79f38131926 100644 --- a/include/video/atmel_lcdc.h +++ b/include/video/atmel_lcdc.h @@ -41,8 +41,10 @@ struct atmel_lcdfb_pdata { u8 lcd_wiring_mode; unsigned int default_lcdcon2; unsigned int default_dmacon; - void (*atmel_lcdfb_power_control)(int on); + void (*atmel_lcdfb_power_control)(struct atmel_lcdfb_pdata *pdata, int on); struct fb_monspecs *default_monspecs; + + struct list_head pwr_gpios; }; #define ATMEL_LCDC_DMABADDR1 0x00 -- cgit v1.2.3 From 8623ec220b9c9d873ef82d41c9adbac7eec53174 Mon Sep 17 00:00:00 2001 From: Marek Belisko Date: Tue, 29 Oct 2013 23:25:40 +0100 Subject: omapdss: Add new panel driver for Topolly td028ttec1 LCD. Signed-off-by: Marek Belisko Signed-off-by: H. Nikolaus Schaller [tomi.valkeinen@ti.com: made a few funcs static] Signed-off-by: Tomi Valkeinen --- include/video/omap-panel-data.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include/video') diff --git a/include/video/omap-panel-data.h b/include/video/omap-panel-data.h index f7ac8d972af0..69279c013ac4 100644 --- a/include/video/omap-panel-data.h +++ b/include/video/omap-panel-data.h @@ -238,4 +238,17 @@ struct panel_nec_nl8048hl11_platform_data { int qvga_gpio; }; +/** + * panel-tpo-td028ttec1 platform data + * @name: name for display entity + * @source: name of the display entity used as a video source + * @data_lines: number of DPI datalines + */ +struct panel_tpo_td028ttec1_platform_data { + const char *name; + const char *source; + + int data_lines; +}; + #endif /* __OMAP_PANEL_DATA_H */ -- cgit v1.2.3