summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarkus <markus@3c298f89-4303-0410-b956-a3cf2f4a3e73>2010-08-02 10:32:39 +0000
committermarkus <markus@3c298f89-4303-0410-b956-a3cf2f4a3e73>2010-08-02 10:32:39 +0000
commit5aabd845f70068fb7e9e1a31653f171581a9103a (patch)
treee65de2346db2671bb0c9d194d8ba3e8650f2ca65
parent4b368f4353bee5a581c033776b3d5fe2d8031dbc (diff)
LED handling fixes for WRT54-G3Gv2
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22462 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--package/comgt/Makefile4
-rw-r--r--package/comgt/files/3g.sh5
2 files changed, 5 insertions, 4 deletions
diff --git a/package/comgt/Makefile b/package/comgt/Makefile
index 253e12af0..b0a55ffec 100644
--- a/package/comgt/Makefile
+++ b/package/comgt/Makefile
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=comgt
PKG_VERSION:=0.32
-PKG_RELEASE:=4
+PKG_RELEASE:=5
PKG_SOURCE:=$(PKG_NAME).$(PKG_VERSION).tgz
PKG_SOURCE_URL:=@SF/comgt
@@ -49,7 +49,7 @@ define Package/comgt/install
$(INSTALL_DATA) ./files/3g.chat $(1)/etc/chatscripts/3g.chat
$(INSTALL_DATA) ./files/evdo.chat $(1)/etc/chatscripts/evdo.chat
$(INSTALL_DIR) $(1)/lib/network
- $(INSTALL_DATA) ./files/3g.sh $(1)/lib/network/3g.sh
+ $(INSTALL_BIN) ./files/3g.sh $(1)/lib/network/3g.sh
$(INSTALL_DIR) $(1)/etc/hotplug.d/button
$(INSTALL_DATA) ./files/3g.button $(1)/etc/hotplug.d/button/05-3g
$(INSTALL_DIR) $(1)/etc/hotplug.d/iface
diff --git a/package/comgt/files/3g.sh b/package/comgt/files/3g.sh
index 59e99c761..c6f8ffbfc 100644
--- a/package/comgt/files/3g.sh
+++ b/package/comgt/files/3g.sh
@@ -1,9 +1,10 @@
set_3g_led() {
# set on WRT54G3G only
- [ -d /proc/diag ] || return 0
- grep WRT54G3G /proc/diag/model >/dev/null || return 0
+ [ -f /proc/diag/model ] || return 0
+ grep -q "WRT54G3G" /proc/diag/model >/dev/null || return 0
echo "$1" > /proc/diag/led/3g_green
echo "$2" > /proc/diag/led/3g_blue
+ grep -q "WRT54G3G$" /proc/diag/model >/dev/null || return 0
echo "$3" > /proc/diag/led/3g_blink
}