]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[ARM] 4150/1: AT91: LED update
authorAndrew Victor <andrew@sanpeople.com>
Thu, 8 Feb 2007 10:18:14 +0000 (11:18 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Thu, 8 Feb 2007 14:55:30 +0000 (14:55 +0000)
The GPIO pin setup should be handed by the platform-setup code, and not
directly by the driver.

Original patch from David Brownell.

Signed-off-by: Andrew Victor <andrew@sanpeople.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mach-at91/at91rm9200_devices.c
arch/arm/mach-at91/at91sam9260_devices.c
arch/arm/mach-at91/at91sam9261_devices.c
arch/arm/mach-at91/leds.c

index 077c81f9bc56f29b9739a1eec170d4ade3644ef8..2624a4f22d612391aad930a9696795893f654f98 100644 (file)
@@ -594,6 +594,10 @@ u8 at91_leds_timer;
 
 void __init at91_init_leds(u8 cpu_led, u8 timer_led)
 {
+       /* Enable GPIO to access the LEDs */
+       at91_set_gpio_output(cpu_led, 1);
+       at91_set_gpio_output(timer_led, 1);
+
        at91_leds_cpu   = cpu_led;
        at91_leds_timer = timer_led;
 }
index b5d8968e29a71f50e665d83826034f262fab5802..f7d342ccbebf823db392f75759cd6417b5a782d5 100644 (file)
@@ -515,6 +515,10 @@ u8 at91_leds_timer;
 
 void __init at91_init_leds(u8 cpu_led, u8 timer_led)
 {
+       /* Enable GPIO to access the LEDs */
+       at91_set_gpio_output(cpu_led, 1);
+       at91_set_gpio_output(timer_led, 1);
+
        at91_leds_cpu   = cpu_led;
        at91_leds_timer = timer_led;
 }
index b2f6d33d0f8c48b894b39e4dfd405a0e366cf69f..e1504766fd6401127e1af02f7e8cd911c8707675 100644 (file)
@@ -513,6 +513,10 @@ u8 at91_leds_timer;
 
 void __init at91_init_leds(u8 cpu_led, u8 timer_led)
 {
+       /* Enable GPIO to access the LEDs */
+       at91_set_gpio_output(cpu_led, 1);
+       at91_set_gpio_output(timer_led, 1);
+
        at91_leds_cpu   = cpu_led;
        at91_leds_timer = timer_led;
 }
index 1a333730466ef2d052d9dee907bce838a870bf60..0d5144973988e6484681d0cde72d233e93378cfb 100644 (file)
@@ -86,10 +86,6 @@ static int __init leds_init(void)
        if (!at91_leds_timer || !at91_leds_cpu)
                return -ENODEV;
 
-       /* Enable PIO to access the LEDs */
-       at91_set_gpio_output(at91_leds_timer, 1);
-       at91_set_gpio_output(at91_leds_cpu, 1);
-
        leds_event = at91_leds_event;
 
        leds_event(led_start);