diff options
author | florian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-04-20 10:27:46 +0000 |
---|---|---|
committer | florian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-04-20 10:27:46 +0000 |
commit | 97ad75a40a47df06bbec7a4a4f6b9c117d110967 (patch) | |
tree | 6119805d553fe7f400787757248b263a97fbf5b9 /package/switch | |
parent | 3704ea377275af3e2dc3261f40cba507bc584ad5 (diff) |
[package] fix strange LED behavior with Netgear WGT634U (#3552)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@15290 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/switch')
-rw-r--r-- | package/switch/Makefile | 2 | ||||
-rw-r--r-- | package/switch/src/switch-robo.c | 8 |
2 files changed, 7 insertions, 3 deletions
diff --git a/package/switch/Makefile b/package/switch/Makefile index 1a5f46f3f..a9b881c40 100644 --- a/package/switch/Makefile +++ b/package/switch/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=kmod-switch -PKG_RELEASE:=1 +PKG_RELEASE:=2 include $(INCLUDE_DIR)/package.mk diff --git a/package/switch/src/switch-robo.c b/package/switch/src/switch-robo.c index 5733d5024..46abc94e9 100644 --- a/package/switch/src/switch-robo.c +++ b/package/switch/src/switch-robo.c @@ -68,6 +68,9 @@ #define bool int #endif + +extern char *nvram_get(const char *name); + /* Data structure for a Roboswitch device. */ struct robo_switch { char *device; /* The device name string (ethX) */ @@ -271,8 +274,9 @@ static int robo_switch_enable(void) robo_write16(ROBO_CTRL_PAGE, i, 0); } - /* WAN port LED */ - robo_write16(ROBO_CTRL_PAGE, 0x16, 0x1F); + /* WAN port LED, except for Netgear WGT634U */ + if (strcmp(nvram_get("nvram_type"), "cfe")) + robo_write16(ROBO_CTRL_PAGE, 0x16, 0x1F); return 0; } |