aboutsummaryrefslogtreecommitdiffstats
path: root/package/broadcom-wl
diff options
context:
space:
mode:
authorAndy Boyett <agb@openwrt.org>2009-01-31 16:08:19 +0000
committerAndy Boyett <agb@openwrt.org>2009-01-31 16:08:19 +0000
commit28216492767f0ffe8b7a82f5dac6efd87adfaf74 (patch)
tree9766508173457d4a7bf542254e636858758b6433 /package/broadcom-wl
parent2f386223ed7fd0d9e5c9f7044e98e72d4fe61f71 (diff)
downloadmaster-187ad058-28216492767f0ffe8b7a82f5dac6efd87adfaf74.tar.gz
master-187ad058-28216492767f0ffe8b7a82f5dac6efd87adfaf74.tar.bz2
master-187ad058-28216492767f0ffe8b7a82f5dac6efd87adfaf74.zip
[package] broadcom-wl: move txpower back to wifi-device section, but remain backwards compatible
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@14306 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/broadcom-wl')
-rw-r--r--package/broadcom-wl/Makefile6
-rw-r--r--package/broadcom-wl/files/lib/wifi/broadcom.sh11
2 files changed, 11 insertions, 6 deletions
diff --git a/package/broadcom-wl/Makefile b/package/broadcom-wl/Makefile
index 345f849994..e49fc50a88 100644
--- a/package/broadcom-wl/Makefile
+++ b/package/broadcom-wl/Makefile
@@ -1,5 +1,5 @@
-#
-# Copyright (C) 2006 OpenWrt.org
+#
+# Copyright (C) 2006-2009 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
@@ -11,7 +11,7 @@ include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=broadcom-wl
PKG_VERSION:=4.150.10.5.3
-PKG_RELEASE:=1
+PKG_RELEASE:=2
WLC_VERSION:=0.1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
diff --git a/package/broadcom-wl/files/lib/wifi/broadcom.sh b/package/broadcom-wl/files/lib/wifi/broadcom.sh
index 4c03aff04c..12002121a6 100644
--- a/package/broadcom-wl/files/lib/wifi/broadcom.sh
+++ b/package/broadcom-wl/files/lib/wifi/broadcom.sh
@@ -123,7 +123,8 @@ enable_broadcom() {
config_get macfilter "$device" macfilter
config_get maclist "$device" maclist
config_get macaddr "$device" macaddr
- local vif_pre_up vif_post_up vif_do_up txpower
+ config_get txpower "$device" txpower
+ local vif_pre_up vif_post_up vif_do_up vif_txpower
_c=0
nas="$(which nas)"
@@ -152,7 +153,7 @@ enable_broadcom() {
esac
for vif in $vifs; do
- config_get txpower "$vif" txpower
+ config_get vif_txpower "$vif" txpower
config_get mode "$vif" mode
append vif_pre_up "vif $_c" "$N"
@@ -305,7 +306,11 @@ EOF
wlc stdin <<EOF
$vif_do_up
EOF
- [ -z "$txpower" ] || iwconfig $device txpower ${txpower}dBm
+
+ # use vif_txpower (from last wifi-iface) instead of txpower (from
+ # wifi-device) if the latter does not exist
+ txpower=${txpower:-$vif_txpower}
+ [ -z "$txpower" ] || iwconfig $device txpower ${txpower}dBm
eval "$nas_cmd"
}