summaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
authorhauke <hauke@3c298f89-4303-0410-b956-a3cf2f4a3e73>2013-01-03 02:07:11 +0000
committerhauke <hauke@3c298f89-4303-0410-b956-a3cf2f4a3e73>2013-01-03 02:07:11 +0000
commit096fa4a7f7a970bbeaf814d8dbbdae43f9f98fbb (patch)
tree32150cd72fb47d51d76d6bf314b47c842442c84e /package
parentd20e9437d56d1204649c450a36afdbc29afb6d19 (diff)
broadcom-diag: add diag support for Linksys E1000 V1
This adds diag leds/buttons support for Linksys E1000 V1. It worked on my router, however it may need some tweaking by people more familiar with openwrt and c to make it fit for commiting. Thank you hhm for this patch. git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34996 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package')
-rw-r--r--package/broadcom-diag/src/diag.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/package/broadcom-diag/src/diag.c b/package/broadcom-diag/src/diag.c
index 7e0ff02e1..997fbe864 100644
--- a/package/broadcom-diag/src/diag.c
+++ b/package/broadcom-diag/src/diag.c
@@ -63,6 +63,7 @@ enum {
WRT600NV11,
WRT610N,
WRT610NV2,
+ E1000V1,
E3000V1,
/* ASUS */
@@ -421,6 +422,25 @@ static struct platform_t __initdata platforms[] = {
{ .name = "wlan", .gpio = 1 << 1, .polarity = NORMAL }, // Wireless LED
},
},
+ /* same hardware as WRT160NV3 and Cisco Valet M10V1, but different board detection, combine? */
+ [E1000V1] = {
+ .name = "Linksys E1000 V1",
+ .buttons = {
+ { .name = "reset", .gpio = 1 << 6 },
+ { .name = "wps", .gpio = 1 << 5 }, /* nvram get gpio5=wps_button */
+ },
+ .leds = {
+ /** turns on leds for all ethernet ports (wan too)
+ * this also disconnects some, or maybe all, ethernet ports
+ * 1: leds work normally
+ * 0: all lit all the time */
+ /* nvram get gpio3=robo_reset */
+ { .name = "wlan", .gpio = 1 << 0, .polarity = NORMAL },
+ { .name = "power", .gpio = 1 << 1, .polarity = NORMAL },
+ { .name = "ses_blue", .gpio = 1 << 4, .polarity = REVERSE }, /* nvram get gpio4=wps_led */
+ { .name = "ses_orange", .gpio = 1 << 2, .polarity = REVERSE }, /* nvram get gpio2=wps_status_led */
+ },
+ },
[E3000V1] = {
.name = "Linksys E3000 V1",
.buttons = {
@@ -1156,6 +1176,13 @@ static struct platform_t __init *platform_detect(void)
}
}
+ if (!strcmp(boardtype, "0x04cd")) {
+ if (!strcmp(getvar("boot_hw_model"), "E100")) {
+ if (!strcmp(getvar("boot_hw_ver"), "1.0"))
+ return &platforms[E1000V1];
+ }
+ }
+
/* default to WRT54G */
return &platforms[WRT54G];
}