[backfire] merge r22462, r22561, r25621 and r26175
authorJo-Philipp Wich <jow@openwrt.org>
Tue, 15 Mar 2011 09:15:35 +0000 (09:15 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Tue, 15 Mar 2011 09:15:35 +0000 (09:15 +0000)
SVN-Revision: 26177

package/comgt/Makefile
package/comgt/files/3g.sh
package/comgt/files/3g.usb

index e8ce8d44853d893571e96b60ae2bc6a9fa4bc4c8..458c132c8bf31275a11b9c4496f30e0c38ed121f 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006-2010 OpenWrt.org
+# Copyright (C) 2006-2011 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=comgt
 PKG_VERSION:=0.32
-PKG_RELEASE:=4
+PKG_RELEASE:=8
 
 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
index b1ce2abae66a5d986ad93d0d6f740129a197b43e..616beec4c4d76ba9602ddeb76108ab0633e9c6a1 100644 (file)
@@ -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
 }
 
index c52646b3dde3a21d31185a78f89e7cb9b4652b99..d5a38b8a4ccfdd38723bd89c3cb1c194f0414626 100644 (file)
@@ -36,8 +36,8 @@ if [ "$ACTION" = add ]; then
        esac
 
        local tty
-       for tty in /sys/$DEVPATH/ttyUSB*; do
-               [ -d "$tty" ] || break
+       for tty in /sys/$DEVPATH/ttyUSB* /sys/$DEVPATH/tty/ttyACM* /sys/$DEVPATH/tty/ttyHS*; do
+               [ -d "$tty" ] || continue
                config_foreach find_3g_iface interface "$tty"
        done
 fi