aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/debugfs.c2
-rw-r--r--net/mac80211/key.c18
-rw-r--r--net/mac80211/main.c18
3 files changed, 14 insertions, 24 deletions
diff --git a/net/mac80211/debugfs.c b/net/mac80211/debugfs.c
index 2e7f75938c51..47435f57e086 100644
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
@@ -271,8 +271,6 @@ static const char *hw_flag_names[] = {
271 FLAG(TX_STATUS_NO_AMPDU_LEN), 271 FLAG(TX_STATUS_NO_AMPDU_LEN),
272 FLAG(SUPPORTS_MULTI_BSSID), 272 FLAG(SUPPORTS_MULTI_BSSID),
273 FLAG(SUPPORTS_ONLY_HE_MULTI_BSSID), 273 FLAG(SUPPORTS_ONLY_HE_MULTI_BSSID),
274 FLAG(EXT_KEY_ID_NATIVE),
275 FLAG(NO_AMPDU_KEYBORDER_SUPPORT),
276#undef FLAG 274#undef FLAG
277}; 275};
278 276
diff --git a/net/mac80211/key.c b/net/mac80211/key.c
index dd60f6428049..92c3affb0eb0 100644
--- a/net/mac80211/key.c
+++ b/net/mac80211/key.c
@@ -270,8 +270,7 @@ int ieee80211_set_tx_key(struct ieee80211_key *key)
270 270
271 sta->ptk_idx = key->conf.keyidx; 271 sta->ptk_idx = key->conf.keyidx;
272 272
273 if (ieee80211_hw_check(&local->hw, NO_AMPDU_KEYBORDER_SUPPORT)) 273 clear_sta_flag(sta, WLAN_STA_BLOCK_BA);
274 clear_sta_flag(sta, WLAN_STA_BLOCK_BA);
275 ieee80211_check_fast_xmit(sta); 274 ieee80211_check_fast_xmit(sta);
276 275
277 return 0; 276 return 0;
@@ -289,16 +288,15 @@ static void ieee80211_pairwise_rekey(struct ieee80211_key *old,
289 if (new->conf.flags & IEEE80211_KEY_FLAG_NO_AUTO_TX) { 288 if (new->conf.flags & IEEE80211_KEY_FLAG_NO_AUTO_TX) {
290 /* Extended Key ID key install, initial one or rekey */ 289 /* Extended Key ID key install, initial one or rekey */
291 290
292 if (sta->ptk_idx != INVALID_PTK_KEYIDX && 291 if (sta->ptk_idx != INVALID_PTK_KEYIDX) {
293 ieee80211_hw_check(&local->hw,
294 NO_AMPDU_KEYBORDER_SUPPORT)) {
295 /* Aggregation Sessions with Extended Key ID must not 292 /* Aggregation Sessions with Extended Key ID must not
296 * mix MPDUs with different keyIDs within one A-MPDU. 293 * mix MPDUs with different keyIDs within one A-MPDU.
297 * Tear down any running Tx aggregation and all new 294 * Tear down running Tx aggregation sessions and block
298 * Rx/Tx aggregation request during rekey if the driver 295 * new Rx/Tx aggregation requests during rekey to
299 * asks us to do so. (Blocking Tx only would be 296 * ensure there are no A-MPDUs for the driver to
300 * sufficient but WLAN_STA_BLOCK_BA gets the job done 297 * aggregate. (Blocking Tx only would be sufficient but
301 * for the few ms we need it.) 298 * WLAN_STA_BLOCK_BA gets the job done for the few ms
299 * we need it.)
302 */ 300 */
303 set_sta_flag(sta, WLAN_STA_BLOCK_BA); 301 set_sta_flag(sta, WLAN_STA_BLOCK_BA);
304 mutex_lock(&sta->ampdu_mlme.mtx); 302 mutex_lock(&sta->ampdu_mlme.mtx);
diff --git a/net/mac80211/main.c b/net/mac80211/main.c
index 4c2702f128f3..29b9d57df1a3 100644
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -1048,21 +1048,15 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
1048 } 1048 }
1049 } 1049 }
1050 1050
1051 /* Enable Extended Key IDs when driver allowed it, or when it 1051 /* Mac80211 and therefore all drivers using SW crypto only
1052 * supports neither HW crypto nor A-MPDUs 1052 * are able to handle PTK rekeys and Extended Key ID.
1053 */ 1053 */
1054 if ((!local->ops->set_key && 1054 if (!local->ops->set_key) {
1055 !ieee80211_hw_check(hw, AMPDU_AGGREGATION)) ||
1056 ieee80211_hw_check(&local->hw, EXT_KEY_ID_NATIVE))
1057 wiphy_ext_feature_set(local->hw.wiphy,
1058 NL80211_EXT_FEATURE_EXT_KEY_ID);
1059
1060 /* Mac80211 and therefore all cards only using SW crypto are able to
1061 * handle PTK rekeys correctly
1062 */
1063 if (!local->ops->set_key)
1064 wiphy_ext_feature_set(local->hw.wiphy, 1055 wiphy_ext_feature_set(local->hw.wiphy,
1065 NL80211_EXT_FEATURE_CAN_REPLACE_PTK0); 1056 NL80211_EXT_FEATURE_CAN_REPLACE_PTK0);
1057 wiphy_ext_feature_set(local->hw.wiphy,
1058 NL80211_EXT_FEATURE_EXT_KEY_ID);
1059 }
1066 1060
1067 /* 1061 /*
1068 * Calculate scan IE length -- we need this to alloc 1062 * Calculate scan IE length -- we need this to alloc