aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2012-09-04 11:08:23 -0400
committerJohannes Berg <johannes.berg@intel.com>2012-09-10 05:29:17 -0400
commite548c49e6dc6b08b59042930a2e90c69c13c9293 (patch)
tree76973d2c36413b68fe646fedefd7d58c41645fff /drivers
parent2cc59e784b54fb95accbd5f5a9d12041eec72dbc (diff)
mac80211: add key flag for management keys
Mark keys that might be used to receive management frames so drivers can fall back on software crypto for them if they don't support hardware offload. As the new flag is only set correctly for RX keys and the existing IEEE80211_KEY_FLAG_SW_MGMT flag can only affect TX, also rename the latter to IEEE80211_KEY_FLAG_SW_MGMT_TX. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ath/ath5k/mac80211-ops.c2
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_main.c2
-rw-r--r--drivers/net/wireless/ath/ath9k/main.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath5k/mac80211-ops.c b/drivers/net/wireless/ath/ath5k/mac80211-ops.c
index c89fa6ead615..155c70e4c26c 100644
--- a/drivers/net/wireless/ath/ath5k/mac80211-ops.c
+++ b/drivers/net/wireless/ath/ath5k/mac80211-ops.c
@@ -524,7 +524,7 @@ ath5k_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
524 if (key->cipher == WLAN_CIPHER_SUITE_TKIP) 524 if (key->cipher == WLAN_CIPHER_SUITE_TKIP)
525 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC; 525 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
526 if (key->cipher == WLAN_CIPHER_SUITE_CCMP) 526 if (key->cipher == WLAN_CIPHER_SUITE_CCMP)
527 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT; 527 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT_TX;
528 ret = 0; 528 ret = 0;
529 } 529 }
530 break; 530 break;
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_main.c b/drivers/net/wireless/ath/ath9k/htc_drv_main.c
index c32f6e3ffb18..a6bb6e3698ca 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_main.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_main.c
@@ -1449,7 +1449,7 @@ static int ath9k_htc_set_key(struct ieee80211_hw *hw,
1449 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC; 1449 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
1450 if (priv->ah->sw_mgmt_crypto && 1450 if (priv->ah->sw_mgmt_crypto &&
1451 key->cipher == WLAN_CIPHER_SUITE_CCMP) 1451 key->cipher == WLAN_CIPHER_SUITE_CCMP)
1452 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT; 1452 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT_TX;
1453 ret = 0; 1453 ret = 0;
1454 } 1454 }
1455 break; 1455 break;
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index 4d8dc9ff5a75..06c628e85a43 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -1441,7 +1441,7 @@ static int ath9k_set_key(struct ieee80211_hw *hw,
1441 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC; 1441 key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
1442 if (sc->sc_ah->sw_mgmt_crypto && 1442 if (sc->sc_ah->sw_mgmt_crypto &&
1443 key->cipher == WLAN_CIPHER_SUITE_CCMP) 1443 key->cipher == WLAN_CIPHER_SUITE_CCMP)
1444 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT; 1444 key->flags |= IEEE80211_KEY_FLAG_SW_MGMT_TX;
1445 ret = 0; 1445 ret = 0;
1446 } 1446 }
1447 break; 1447 break;