From: Andrew Victor Date: Thu, 18 Sep 2008 18:48:32 +0000 (+0100) Subject: [ARM] 5261/1: [AT91] Support for LEDs on Conitec ARM&EVA board X-Git-Tag: v2.6.28-rc1~293^2~7^2~1 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=bf07e4404ebb0911d378172c01748bf822343cde;p=linux-2.6-omap-h63xx.git [ARM] 5261/1: [AT91] Support for LEDs on Conitec ARM&EVA board Add support for the LEDs on the Conitec ARM&EVA board. Signed-off-by: Andrew Victor Signed-off-by: Russell King --- diff --git a/arch/arm/mach-at91/board-carmeva.c b/arch/arm/mach-at91/board-carmeva.c index afa1ff0e957..db1f9544d2e 100644 --- a/arch/arm/mach-at91/board-carmeva.c +++ b/arch/arm/mach-at91/board-carmeva.c @@ -25,7 +25,6 @@ #include #include -#include #include #include #include @@ -34,6 +33,7 @@ #include #include +#include #include #include @@ -114,6 +114,30 @@ static struct spi_board_info carmeva_spi_devices[] = { }, }; +static struct gpio_led carmeva_leds[] = { + { /* "user led 1", LED9 */ + .name = "led9", + .gpio = AT91_PIN_PA21, + .active_low = 1, + .default_trigger = "heartbeat", + }, + { /* "user led 2", LED10 */ + .name = "led10", + .gpio = AT91_PIN_PA25, + .active_low = 1, + }, + { /* "user led 3", LED11 */ + .name = "led11", + .gpio = AT91_PIN_PA26, + .active_low = 1, + }, + { /* "user led 4", LED12 */ + .name = "led12", + .gpio = AT91_PIN_PA18, + .active_low = 1, + } +}; + static void __init carmeva_board_init(void) { /* Serial */ @@ -132,6 +156,8 @@ static void __init carmeva_board_init(void) // at91_add_device_cf(&carmeva_cf_data); /* MMC */ at91_add_device_mmc(0, &carmeva_mmc_data); + /* LEDs */ + at91_gpio_leds(carmeva_leds, ARRAY_SIZE(carmeva_leds)); } MACHINE_START(CARMEVA, "Carmeva")