aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2014-04-12 17:42:34 +0000
committerGabor Juhos <juhosg@openwrt.org>2014-04-12 17:42:34 +0000
commit701b173389b27f3f2367cbdc1012097d56d29867 (patch)
treee4c278212053b68c9981bd398adda7af60fb5b5c /target/linux
parent8204dc3a79b4b37428be819d852a558710438d13 (diff)
downloadmaster-187ad058-701b173389b27f3f2367cbdc1012097d56d29867.tar.gz
master-187ad058-701b173389b27f3f2367cbdc1012097d56d29867.tar.bz2
master-187ad058-701b173389b27f3f2367cbdc1012097d56d29867.zip
ar71xx: wndr4300: select GPIO_OUT functionality for LED GPIOs
The bootloader does not initializes the output function correctly for all LEDs. DO that from the board setup code. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@40474 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/ar71xx/files/arch/mips/ath79/mach-wndr4300.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-wndr4300.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-wndr4300.c
index d67b8f85e1..a89b8b6827 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-wndr4300.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-wndr4300.c
@@ -155,6 +155,12 @@ static struct mdio_board_info wndr4300_mdio0_info[] = {
static void __init wndr4300_setup(void)
{
+ int i;
+
+ for (i = 0; i < ARRAY_SIZE(wndr4300_leds_gpio); i++)
+ ath79_gpio_output_select(wndr4300_leds_gpio[i].gpio,
+ AR934X_GPIO_OUT_GPIO);
+
ath79_register_leds_gpio(-1, ARRAY_SIZE(wndr4300_leds_gpio),
wndr4300_leds_gpio);
ath79_register_gpio_keys_polled(-1, WNDR4300_KEYS_POLL_INTERVAL,