mac80211: move txpower to wifi-device section, but remain backwards compatible

SVN-Revision: 14309
This commit is contained in:
Andy Boyett 2009-01-31 16:09:39 +00:00
parent 6360bd2798
commit 0da13fa8ba
2 changed files with 7 additions and 5 deletions

View file

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=mac80211 PKG_NAME:=mac80211
PKG_RELEASE:=1 PKG_RELEASE:=2
ifneq ($(CONFIG_LINUX_2_6_27)$(CONFIG_LINUX_2_6_28),) ifneq ($(CONFIG_LINUX_2_6_27)$(CONFIG_LINUX_2_6_28),)
PKG_VERSION:=2009-01-29 PKG_VERSION:=2009-01-29

View file

@ -50,6 +50,7 @@ enable_mac80211() {
local device="$1" local device="$1"
config_get channel "$device" channel config_get channel "$device" channel
config_get vifs "$device" vifs config_get vifs "$device" vifs
config_get txpower "$device" txpower
local first=1 local first=1
for vif in $vifs; do for vif in $vifs; do
@ -112,10 +113,11 @@ enable_mac80211() {
esac esac
config_get ssid "$vif" ssid config_get ssid "$vif" ssid
config_get txpwr "$vif" txpower config_get vif_txpower "$vif" txpower
if [ -n "$txpwr" ]; then # use vif_txpower (from wifi-iface) to override txpower (from
iwconfig "$ifname" txpower "${txpwr%%.*}" # wifi-device) if the latter doesn't exist
fi txpower="${txpower:-$vif_txpower}"
[ -z "$txpower" ] || iwconfig "$ifname" txpower "${txpower%%.*}"
config_get frag "$vif" frag config_get frag "$vif" frag
if [ -n "$frag" ]; then if [ -n "$frag" ]; then