mac80211: update sta bw on ht chanwidth action frame
authorEliad Peller <eliad@wizery.com>
Sun, 14 Dec 2014 09:05:51 +0000 (11:05 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 17 Dec 2014 14:45:16 +0000 (15:45 +0100)
commit1c45c5ce324fec967dca5993f79b54769da410dc
tree0dc0d83ef40d736f205d1570aec856d6b6d2889f
parenta5fee9cb6255b9bba5a977f92cb4807eafb89db0
mac80211: update sta bw on ht chanwidth action frame

Commit e1a0c6b ("mac80211: stop toggling IEEE80211_HT_CAP_SUP_WIDTH_20_40")
mistakenly removed the actual update of sta->sta.bandwidth.

Refactor ieee80211_sta_cur_vht_bw() into multiple functions
(calculate caps-bw and chandef-bw separately, and min them
with cur_max_bandwidth).

On ht chanwidth action frame set only cur_max_bandwidth
(according to the sta capabilities) and recalc the sta bw.

Signed-off-by: Eliad Peller <eliadx.peller@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/ieee80211_i.h
net/mac80211/rx.c
net/mac80211/vht.c