diff options
author | Geert Uytterhoeven <geert+renesas@glider.be> | 2014-05-14 16:51:21 +0200 |
---|---|---|
committer | Simon Horman <horms+renesas@verge.net.au> | 2014-06-17 19:35:58 +0900 |
commit | 111bcc1360235ad1cdab4bc27f5ccca943ca8af5 (patch) | |
tree | 475b97c678266208a4fa511e4cbf6c36c14325d5 /arch/arm | |
parent | f47b9e1ec3a1d694f07fcc0d5ba0c2582acce099 (diff) |
ARM: shmobile: armadillo800eva legacy: Add LED support
Cfr. r8a7740-armadillo800eva-reference.dts
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-shmobile/board-armadillo800eva.c | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index 53d03e85750a..395638da837c 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -578,6 +578,40 @@ static struct platform_device hdmi_lcdc_device = { }, }; +/* LEDS */ +static struct gpio_led gpio_leds[] = { + { + .name = "LED3", + .gpio = 102, + .default_state = LEDS_GPIO_DEFSTATE_ON, + }, { + .name = "LED4", + .gpio = 111, + .default_state = LEDS_GPIO_DEFSTATE_ON, + }, { + .name = "LED5", + .gpio = 110, + .default_state = LEDS_GPIO_DEFSTATE_ON, + }, { + .name = "LED6", + .gpio = 177, + .default_state = LEDS_GPIO_DEFSTATE_ON, + }, +}; + +static struct gpio_led_platform_data leds_gpio_info = { + .leds = gpio_leds, + .num_leds = ARRAY_SIZE(gpio_leds), +}; + +static struct platform_device leds_gpio_device = { + .name = "leds-gpio", + .id = -1, + .dev = { + .platform_data = &leds_gpio_info, + }, +}; + /* GPIO KEY */ #define GPIO_KEY(c, g, d, ...) \ { .code = c, .gpio = g, .desc = d, .active_low = 1, __VA_ARGS__ } @@ -1069,6 +1103,7 @@ static struct platform_device *eva_devices[] __initdata = { &lcdc0_device, &pwm_device, &pwm_backlight_device, + &leds_gpio_device, &gpio_keys_device, &sh_eth_device, &vcc_sdhi0, |