diff options
author | Felix Fietkau <nbd@openwrt.org> | 2014-02-03 13:31:44 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2014-02-03 13:31:44 +0000 |
commit | 38587f87ed27ea0b1db59103a219a6270575f1d3 (patch) | |
tree | 1c888a4dbcca2c7ce449e9c7c476c671e796a734 /package/kernel/mac80211/files/lib/wifi/mac80211.sh | |
parent | 169213a1b44f03fb9831bff15cc35ac384a947f3 (diff) | |
download | upstream-38587f87ed27ea0b1db59103a219a6270575f1d3.tar.gz upstream-38587f87ed27ea0b1db59103a219a6270575f1d3.tar.bz2 upstream-38587f87ed27ea0b1db59103a219a6270575f1d3.zip |
wifi: Introduce 802.11ac support
This patch introduces 802.11ac support to mac80211 and hostapd. The split of
VHT160 in two 80 MHz bands is not yet supported, since it requires an
additional user supplied parameter for the channel of the second band.
Signed-off-by: Matti Laakso <malaakso@elisanet.fi>
Signed-off-by: Simon Wunderlich <simon@open-mesh.com>
[sven@open-mesh.com: Rebased patch, merged htmode and vhtmode,
removed special hwmode, replaced uci vht_capab list with overwritable
autoconfig, fixed hostapd integration, fixed commit description, add HT40+/-
for VHT modes, add VHT40 center_freq autoconfig, refactored major parts]
Signed-off-by: Sven Eckelmann <sven@open-mesh.com>
SVN-Revision: 39456
Diffstat (limited to 'package/kernel/mac80211/files/lib/wifi/mac80211.sh')
-rw-r--r-- | package/kernel/mac80211/files/lib/wifi/mac80211.sh | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh index e33b09abb2..e299ab939f 100644 --- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh +++ b/package/kernel/mac80211/files/lib/wifi/mac80211.sh @@ -69,6 +69,8 @@ detect_mac80211() { mode_11n="" mode_band="g" channel="11" + htmode="" + ht_cap=0 for cap in $(iw phy "$dev" info | grep 'Capabilities:' | cut -d: -f2); do ht_cap="$(($ht_cap | $cap))" @@ -76,7 +78,7 @@ detect_mac80211() { ht_capab=""; [ "$ht_cap" -gt 0 ] && { mode_11n="n" - append ht_capab " option htmode HT20" "$N" + htmode="HT20" list=" list ht_capab" [ "$(($ht_cap & 1))" -eq 1 ] && append ht_capab "$list LDPC" "$N" @@ -91,6 +93,15 @@ detect_mac80211() { } iw phy "$dev" info | grep -q '2412 MHz' || { mode_band="a"; channel="36"; } + vht_cap=$(iw phy "$dev" info | grep -c 'VHT Capabilities') + [ "$vht_cap" -gt 0 ] && { + mode_band="a"; + channel="36" + htmode="VHT80" + } + + [ -n $htmode ] && append ht_capab " option htmode $htmode" "$N" + if [ -x /usr/bin/readlink ]; then path="$(readlink -f /sys/class/ieee80211/${dev}/device)" path="${path##/sys/devices/}" |