diff options
author | Andrew Victor <linux@maxim.org.za> | 2008-01-23 09:32:17 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-01-26 15:00:32 +0000 |
commit | 1b41bdf68a72c1fd506ee3dbfbf954fd2eaef75c (patch) | |
tree | 163781e6480984fe948a5e22e826f684e0d4ab7d /arch/arm/mach-at91/board-sam9263ek.c | |
parent | 2743f0c1dcca54d6c80b0de1273b3f4e90051a85 (diff) |
[ARM] 4761/1: [AT91] Board-support for NEW_LEDs
Add NEW_LEDs support for the following boards:
- Cogent CSB337
- Atmel AT91RM9200-DK
- Atmel AT91RM9200-EK
- Atmel AT91SAM9263-EK
Mostly based on patch from David Brownell.
Signed-off-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-at91/board-sam9263ek.c')
-rw-r--r-- | arch/arm/mach-at91/board-sam9263ek.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/arch/arm/mach-at91/board-sam9263ek.c b/arch/arm/mach-at91/board-sam9263ek.c index a9dd59543ec..2df0ff25d14 100644 --- a/arch/arm/mach-at91/board-sam9263ek.c +++ b/arch/arm/mach-at91/board-sam9263ek.c @@ -272,6 +272,30 @@ static struct atmel_ac97_data ek_ac97_data = { }; +/* + * LEDs ... these could all be PWM-driven, for variable brightness + */ +static struct gpio_led ek_leds[] = { + { /* "left" led, green, userled1, pwm1 */ + .name = "ds1", + .gpio = AT91_PIN_PB8, + .active_low = 1, + .default_trigger = "mmc0", + }, + { /* "right" led, green, userled2, pwm2 */ + .name = "ds2", + .gpio = AT91_PIN_PC29, + .active_low = 1, + .default_trigger = "nand-disk", + }, + { /* "power" led, yellow, pwm0 */ + .name = "ds3", + .gpio = AT91_PIN_PB7, + .default_trigger = "heartbeat", + }, +}; + + static void __init ek_board_init(void) { /* Serial */ @@ -297,6 +321,8 @@ static void __init ek_board_init(void) at91_add_device_lcdc(&ek_lcdc_data); /* AC97 */ at91_add_device_ac97(&ek_ac97_data); + /* LEDs */ + at91_gpio_leds(ek_leds, ARRAY_SIZE(ek_leds)); } MACHINE_START(AT91SAM9263EK, "Atmel AT91SAM9263-EK") |