aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/ibss.c
diff options
context:
space:
mode:
authorSimon Wunderlich <simon.wunderlich@s2003.tu-chemnitz.de>2011-11-30 10:56:33 -0500
committerJohn W. Linville <linville@tuxdriver.com>2011-12-06 16:05:25 -0500
commitff3cc5f40f36db1a60a8f1051be7fbc92233419b (patch)
tree9348704f13be3aa3985aa1dc54cb8bf7e4d9af32 /net/mac80211/ibss.c
parent54858ee5bf659f80a784303e41ee8898fd163f98 (diff)
mac80211: handle protection mode, RIFS and ADDBA for HT IBSS
* Follow 802.11n-2009 9.13.3.1 for protection mode and ADDBA * Send ADDBA only to HT STAs - implement 11.5.1.1 partially Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by: Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Reviewed-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/ibss.c')
-rw-r--r--net/mac80211/ibss.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
index 7d84af70132f..a82f6b4adb58 100644
--- a/net/mac80211/ibss.c
+++ b/net/mac80211/ibss.c
@@ -896,6 +896,7 @@ int ieee80211_ibss_join(struct ieee80211_sub_if_data *sdata,
896 struct cfg80211_ibss_params *params) 896 struct cfg80211_ibss_params *params)
897{ 897{
898 struct sk_buff *skb; 898 struct sk_buff *skb;
899 u32 changed = 0;
899 900
900 skb = dev_alloc_skb(sdata->local->hw.extra_tx_headroom + 901 skb = dev_alloc_skb(sdata->local->hw.extra_tx_headroom +
901 36 /* bitrates */ + 902 36 /* bitrates */ +
@@ -951,6 +952,23 @@ int ieee80211_ibss_join(struct ieee80211_sub_if_data *sdata,
951 ieee80211_recalc_idle(sdata->local); 952 ieee80211_recalc_idle(sdata->local);
952 mutex_unlock(&sdata->local->mtx); 953 mutex_unlock(&sdata->local->mtx);
953 954
955 /*
956 * 802.11n-2009 9.13.3.1: In an IBSS, the HT Protection field is
957 * reserved, but an HT STA shall protect HT transmissions as though
958 * the HT Protection field were set to non-HT mixed mode.
959 *
960 * In an IBSS, the RIFS Mode field of the HT Operation element is
961 * also reserved, but an HT STA shall operate as though this field
962 * were set to 1.
963 */
964
965 sdata->vif.bss_conf.ht_operation_mode |=
966 IEEE80211_HT_OP_MODE_PROTECTION_NONHT_MIXED
967 | IEEE80211_HT_PARAM_RIFS_MODE;
968
969 changed |= BSS_CHANGED_HT;
970 ieee80211_bss_info_change_notify(sdata, changed);
971
954 ieee80211_queue_work(&sdata->local->hw, &sdata->work); 972 ieee80211_queue_work(&sdata->local->hw, &sdata->work);
955 973
956 return 0; 974 return 0;