Commit b9e6342b authored by Mark A. Greer's avatar Mark A. Greer Committed by Kevin Hilman

davinci: Add support for Sharp LCD035Q3DG01 graphical LCD

Add support for the Sharp LCD035Q3DG01 graphical LCD.  This
requires a minor interface change to da8xx_register_lcdc()
so that the board code can pass in the platform_data which
describes the lcd controller that's to be used.
Signed-off-by: default avatarMark A. Greer <mgreer@mvista.com>
Signed-off-by: default avatarKevin Hilman <khilman@deeprootsystems.com>
parent 2eb30c81
...@@ -377,7 +377,7 @@ static __init void da850_evm_init(void) ...@@ -377,7 +377,7 @@ static __init void da850_evm_init(void)
pr_warning("da850_evm_init: lcd initialization failed: %d\n", pr_warning("da850_evm_init: lcd initialization failed: %d\n",
ret); ret);
ret = da8xx_register_lcdc(); ret = da8xx_register_lcdc(&sharp_lk043t1dg01_pdata);
if (ret) if (ret)
pr_warning("da850_evm_init: lcdc registration failed: %d\n", pr_warning("da850_evm_init: lcdc registration failed: %d\n",
ret); ret);
......
...@@ -21,7 +21,6 @@ ...@@ -21,7 +21,6 @@
#include <mach/common.h> #include <mach/common.h>
#include <mach/time.h> #include <mach/time.h>
#include <mach/da8xx.h> #include <mach/da8xx.h>
#include <video/da8xx-fb.h>
#include "clock.h" #include "clock.h"
...@@ -381,7 +380,13 @@ static struct lcd_ctrl_config lcd_cfg = { ...@@ -381,7 +380,13 @@ static struct lcd_ctrl_config lcd_cfg = {
.raster_order = 0, .raster_order = 0,
}; };
static struct da8xx_lcdc_platform_data da850_evm_lcdc_pdata = { struct da8xx_lcdc_platform_data sharp_lcd035q3dg01_pdata = {
.manu_name = "sharp",
.controller_data = &lcd_cfg,
.type = "Sharp_LCD035Q3DG01",
};
struct da8xx_lcdc_platform_data sharp_lk043t1dg01_pdata = {
.manu_name = "sharp", .manu_name = "sharp",
.controller_data = &lcd_cfg, .controller_data = &lcd_cfg,
.type = "Sharp_LK043T1DG01", .type = "Sharp_LK043T1DG01",
...@@ -400,19 +405,17 @@ static struct resource da8xx_lcdc_resources[] = { ...@@ -400,19 +405,17 @@ static struct resource da8xx_lcdc_resources[] = {
}, },
}; };
static struct platform_device da850_lcdc_device = { static struct platform_device da8xx_lcdc_device = {
.name = "da8xx_lcdc", .name = "da8xx_lcdc",
.id = 0, .id = 0,
.num_resources = ARRAY_SIZE(da8xx_lcdc_resources), .num_resources = ARRAY_SIZE(da8xx_lcdc_resources),
.resource = da8xx_lcdc_resources, .resource = da8xx_lcdc_resources,
.dev = {
.platform_data = &da850_evm_lcdc_pdata,
}
}; };
int __init da8xx_register_lcdc(void) int __init da8xx_register_lcdc(struct da8xx_lcdc_platform_data *pdata)
{ {
return platform_device_register(&da850_lcdc_device); da8xx_lcdc_device.dev.platform_data = pdata;
return platform_device_register(&da8xx_lcdc_device);
} }
static struct resource da8xx_mmcsd0_resources[] = { static struct resource da8xx_mmcsd0_resources[] = {
......
...@@ -11,6 +11,8 @@ ...@@ -11,6 +11,8 @@
#ifndef __ASM_ARCH_DAVINCI_DA8XX_H #ifndef __ASM_ARCH_DAVINCI_DA8XX_H
#define __ASM_ARCH_DAVINCI_DA8XX_H #define __ASM_ARCH_DAVINCI_DA8XX_H
#include <video/da8xx-fb.h>
#include <mach/serial.h> #include <mach/serial.h>
#include <mach/edma.h> #include <mach/edma.h>
#include <mach/i2c.h> #include <mach/i2c.h>
...@@ -76,12 +78,14 @@ int da8xx_register_edma(void); ...@@ -76,12 +78,14 @@ int da8xx_register_edma(void);
int da8xx_register_i2c(int instance, struct davinci_i2c_platform_data *pdata); int da8xx_register_i2c(int instance, struct davinci_i2c_platform_data *pdata);
int da8xx_register_watchdog(void); int da8xx_register_watchdog(void);
int da8xx_register_emac(void); int da8xx_register_emac(void);
int da8xx_register_lcdc(void); int da8xx_register_lcdc(struct da8xx_lcdc_platform_data *pdata);
int da8xx_register_mmcsd0(struct davinci_mmc_config *config); int da8xx_register_mmcsd0(struct davinci_mmc_config *config);
void __init da8xx_register_mcasp(int id, struct snd_platform_data *pdata); void __init da8xx_register_mcasp(int id, struct snd_platform_data *pdata);
extern struct platform_device da8xx_serial_device; extern struct platform_device da8xx_serial_device;
extern struct emac_platform_data da8xx_emac_pdata; extern struct emac_platform_data da8xx_emac_pdata;
extern struct da8xx_lcdc_platform_data sharp_lcd035q3dg01_pdata;
extern struct da8xx_lcdc_platform_data sharp_lk043t1dg01_pdata;
extern const short da830_emif25_pins[]; extern const short da830_emif25_pins[];
extern const short da830_spi0_pins[]; extern const short da830_spi0_pins[];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment