ARM: S3C64XX: add backlight control for mach-mini6410
Add support for platform-lcd device for mach-mini6410 Signed-off-by: Darius Augulis <augulis.darius@gmail.com> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
This commit is contained in:
parent
2abca87cb6
commit
bbd7ac63a6
1 changed files with 21 additions and 0 deletions
|
@ -40,6 +40,7 @@
|
||||||
#include <plat/fb.h>
|
#include <plat/fb.h>
|
||||||
#include <plat/nand.h>
|
#include <plat/nand.h>
|
||||||
#include <plat/regs-serial.h>
|
#include <plat/regs-serial.h>
|
||||||
|
#include <video/platform_lcd.h>
|
||||||
|
|
||||||
#define UCON (S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK)
|
#define UCON (S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK)
|
||||||
#define ULCON (S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB)
|
#define ULCON (S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB)
|
||||||
|
@ -182,6 +183,25 @@ static struct s3c_fb_platdata mini6410_lcd_pdata __initdata = {
|
||||||
.vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC,
|
.vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static void mini6410_lcd_power_set(struct plat_lcd_data *pd,
|
||||||
|
unsigned int power)
|
||||||
|
{
|
||||||
|
if (power)
|
||||||
|
gpio_direction_output(S3C64XX_GPE(0), 1);
|
||||||
|
else
|
||||||
|
gpio_direction_output(S3C64XX_GPE(0), 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
static struct plat_lcd_data mini6410_lcd_power_data = {
|
||||||
|
.set_power = mini6410_lcd_power_set,
|
||||||
|
};
|
||||||
|
|
||||||
|
static struct platform_device mini6410_lcd_powerdev = {
|
||||||
|
.name = "platform-lcd",
|
||||||
|
.dev.parent = &s3c_device_fb.dev,
|
||||||
|
.dev.platform_data = &mini6410_lcd_power_data,
|
||||||
|
};
|
||||||
|
|
||||||
static struct platform_device *mini6410_devices[] __initdata = {
|
static struct platform_device *mini6410_devices[] __initdata = {
|
||||||
&mini6410_device_eth,
|
&mini6410_device_eth,
|
||||||
&s3c_device_hsmmc0,
|
&s3c_device_hsmmc0,
|
||||||
|
@ -189,6 +209,7 @@ static struct platform_device *mini6410_devices[] __initdata = {
|
||||||
&s3c_device_ohci,
|
&s3c_device_ohci,
|
||||||
&s3c_device_nand,
|
&s3c_device_nand,
|
||||||
&s3c_device_fb,
|
&s3c_device_fb,
|
||||||
|
&mini6410_lcd_powerdev,
|
||||||
};
|
};
|
||||||
|
|
||||||
static void __init mini6410_map_io(void)
|
static void __init mini6410_map_io(void)
|
||||||
|
|
Loading…
Add table
Reference in a new issue