aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2011-09-29 10:04:41 -0400
committerJohn W. Linville <linville@tuxdriver.com>2011-09-30 15:57:25 -0400
commit49a59543eb5a5d268b3d11747f9c3c557ae271a0 (patch)
treecee8bf84d162eb423833ebddf12211b94161618f /net
parent4b801bc969364a980c1366e48155d1a29d20661b (diff)
mac80211: dont assign seqno to or aggregate QoS Null frames
802.11 says: "Sequence numbers for QoS (+)Null frames may be set to any value." However, if we use the normal counters then peers will get confused with aggregation since there'll be holes in the sequence number sequence. To avoid that, neither assign a sequence number to QoS null frames nor put them on aggregation. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/tx.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 7699e666457f..ae5dd85f1e93 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -804,6 +804,9 @@ ieee80211_tx_h_sequence(struct ieee80211_tx_data *tx)
804 if (ieee80211_hdrlen(hdr->frame_control) < 24) 804 if (ieee80211_hdrlen(hdr->frame_control) < 24)
805 return TX_CONTINUE; 805 return TX_CONTINUE;
806 806
807 if (ieee80211_is_qos_nullfunc(hdr->frame_control))
808 return TX_CONTINUE;
809
807 /* 810 /*
808 * Anything but QoS data that has a sequence number field 811 * Anything but QoS data that has a sequence number field
809 * (is long enough) gets a sequence number from the global 812 * (is long enough) gets a sequence number from the global
@@ -1236,6 +1239,7 @@ ieee80211_tx_prepare(struct ieee80211_sub_if_data *sdata,
1236 tx->sta = sta_info_get(sdata, hdr->addr1); 1239 tx->sta = sta_info_get(sdata, hdr->addr1);
1237 1240
1238 if (tx->sta && ieee80211_is_data_qos(hdr->frame_control) && 1241 if (tx->sta && ieee80211_is_data_qos(hdr->frame_control) &&
1242 !ieee80211_is_qos_nullfunc(hdr->frame_control) &&
1239 (local->hw.flags & IEEE80211_HW_AMPDU_AGGREGATION) && 1243 (local->hw.flags & IEEE80211_HW_AMPDU_AGGREGATION) &&
1240 !(local->hw.flags & IEEE80211_HW_TX_AMPDU_SETUP_IN_HW)) { 1244 !(local->hw.flags & IEEE80211_HW_TX_AMPDU_SETUP_IN_HW)) {
1241 struct tid_ampdu_tx *tid_tx; 1245 struct tid_ampdu_tx *tid_tx;