diff options
author | Felix Fietkau <nbd@openwrt.org> | 2007-11-30 21:58:14 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2007-11-30 21:58:14 +0000 |
commit | 79a61f47df8b0d2eb8610fcbd1417e89e768d33c (patch) | |
tree | 8350c6490cb26f6cea7ac4d983c0c6cf6196b7af /package/broadcom-diag/src | |
parent | 27fc283510e5cd3a80f19996161445816b08c917 (diff) | |
download | upstream-79a61f47df8b0d2eb8610fcbd1417e89e768d33c.tar.gz upstream-79a61f47df8b0d2eb8610fcbd1417e89e768d33c.tar.bz2 upstream-79a61f47df8b0d2eb8610fcbd1417e89e768d33c.zip |
add switch gpio init for bcm57xx (untested, see #2744)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@9642 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/broadcom-diag/src')
-rw-r--r-- | package/broadcom-diag/src/diag.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/package/broadcom-diag/src/diag.c b/package/broadcom-diag/src/diag.c index 07b89d3759..60bf612382 100644 --- a/package/broadcom-diag/src/diag.c +++ b/package/broadcom-diag/src/diag.c @@ -131,6 +131,14 @@ static void __init bcm4780_init(void) { schedule_timeout(HZ * 5); } +static void __init bcm57xx_init(void) { + int pin = 1 << 2; + + gpio_outen(pin, pin); + gpio_control(pin, 0); + gpio_out(pin, pin); +} + static struct platform_t __initdata platforms[] = { /* Linksys */ [WAP54GV1] = { @@ -138,7 +146,7 @@ static struct platform_t __initdata platforms[] = { .buttons = { { .name = "reset", .gpio = 1 << 0 }, }, - .leds = { + .leds = { { .name = "diag", .gpio = 1 << 3 }, { .name = "wlan", .gpio = 1 << 4 }, }, @@ -219,6 +227,7 @@ static struct platform_t __initdata platforms[] = { { .name = "usb_blink", .gpio = 1 << 10, .polarity = REVERSE }, { .name = "usb", .gpio = 1 << 11, .polarity = REVERSE }, }, + .platform_init = bcm57xx_init, }, /* Asus */ [WLHDD] = { |