mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-08-19 04:50:13 +03:00
[package] mac80211: Fix antenna setting when only one of {rx,tx}antenna options is specified
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@25136 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
87e0cf685d
commit
96418c0a98
@ -239,8 +239,8 @@ enable_mac80211() {
|
|||||||
config_get txpower "$device" txpower
|
config_get txpower "$device" txpower
|
||||||
config_get country "$device" country
|
config_get country "$device" country
|
||||||
config_get distance "$device" distance
|
config_get distance "$device" distance
|
||||||
config_get txantenna "$device" txantenna
|
config_get txantenna "$device" txantenna all
|
||||||
config_get rxantenna "$device" rxantenna
|
config_get rxantenna "$device" rxantenna all
|
||||||
config_get frag "$device" frag
|
config_get frag "$device" frag
|
||||||
config_get rts "$device" rts
|
config_get rts "$device" rts
|
||||||
find_mac80211_phy "$device" || return 0
|
find_mac80211_phy "$device" || return 0
|
||||||
@ -256,8 +256,7 @@ enable_mac80211() {
|
|||||||
fixed=1
|
fixed=1
|
||||||
}
|
}
|
||||||
|
|
||||||
local antspec="${txantenna:+$txantenna }$rxantenna"
|
iw phy "$phy" set antenna "$txantenna $rxantenna"
|
||||||
iw phy "$phy" set antenna ${antspec:-all}
|
|
||||||
|
|
||||||
[ -n "$distance" ] && iw phy "$phy" set distance "$distance"
|
[ -n "$distance" ] && iw phy "$phy" set distance "$distance"
|
||||||
[ -n "$frag" ] && iw phy "$phy" set frag "${frag%%.*}"
|
[ -n "$frag" ] && iw phy "$phy" set frag "${frag%%.*}"
|
||||||
|
Loading…
Reference in New Issue
Block a user