summaryrefslogtreecommitdiff
path: root/package
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2011-04-23 21:34:40 +0000
committerFelix Fietkau <nbd@openwrt.org>2011-04-23 21:34:40 +0000
commite15e8f6976a0812fd259860499476d1cad3c268f (patch)
tree3d4181d94a2d63f4d0d85a6516bede8e35c6e376 /package
parentd7bdfca6d0879280b8b6f4e5e2f6e9086421a982 (diff)
downloadmtk-20170518-e15e8f6976a0812fd259860499476d1cad3c268f.zip
mtk-20170518-e15e8f6976a0812fd259860499476d1cad3c268f.tar.gz
mtk-20170518-e15e8f6976a0812fd259860499476d1cad3c268f.tar.bz2
mac80211: do rate control updates when the HT configuration changes on an interface
SVN-Revision: 26750
Diffstat (limited to 'package')
-rw-r--r--package/mac80211/patches/560-mac80211_ht_change_rate_update.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/package/mac80211/patches/560-mac80211_ht_change_rate_update.patch b/package/mac80211/patches/560-mac80211_ht_change_rate_update.patch
new file mode 100644
index 0000000..bff6a6b
--- /dev/null
+++ b/package/mac80211/patches/560-mac80211_ht_change_rate_update.patch
@@ -0,0 +1,35 @@
+--- a/net/mac80211/main.c
++++ b/net/mac80211/main.c
+@@ -245,7 +245,9 @@ void ieee80211_bss_info_change_notify(st
+ u32 changed)
+ {
+ struct ieee80211_local *local = sdata->local;
++ struct ieee80211_supported_band *sband;
+ static const u8 zero[ETH_ALEN] = { 0 };
++ struct sta_info *sta;
+
+ if (!changed)
+ return;
+@@ -275,6 +277,22 @@ void ieee80211_bss_info_change_notify(st
+
+ switch (sdata->vif.type) {
+ case NL80211_IFTYPE_AP:
++ if (!(changed & BSS_CHANGED_HT))
++ break;
++
++ sband = local->hw.wiphy->bands[local->hw.conf.channel->band];
++ rcu_read_lock();
++ list_for_each_entry(sta, &local->sta_list, list) {
++ if (sta->sdata != sdata &&
++ (!sdata->bss || sta->sdata->bss != sdata->bss))
++ continue;
++
++ rate_control_rate_update(local, sband, sta,
++ IEEE80211_RC_HT_CHANGED,
++ local->_oper_channel_type);
++ }
++ rcu_read_unlock();
++ break;
+ case NL80211_IFTYPE_ADHOC:
+ case NL80211_IFTYPE_WDS:
+ case NL80211_IFTYPE_MESH_POINT: