aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/key.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/net/mac80211/key.c b/net/mac80211/key.c
index ca3c626b011a..b510721e3b3d 100644
--- a/net/mac80211/key.c
+++ b/net/mac80211/key.c
@@ -102,7 +102,8 @@ static int ieee80211_key_enable_hw_accel(struct ieee80211_key *key)
102 if (!ret) { 102 if (!ret) {
103 key->flags |= KEY_FLAG_UPLOADED_TO_HARDWARE; 103 key->flags |= KEY_FLAG_UPLOADED_TO_HARDWARE;
104 104
105 if (!(key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_MMIC)) 105 if (!((key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_MMIC) ||
106 (key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_IV)))
106 key->local->crypto_tx_tailroom_needed_cnt--; 107 key->local->crypto_tx_tailroom_needed_cnt--;
107 108
108 return 0; 109 return 0;
@@ -161,7 +162,8 @@ static void ieee80211_key_disable_hw_accel(struct ieee80211_key *key)
161 162
162 key->flags &= ~KEY_FLAG_UPLOADED_TO_HARDWARE; 163 key->flags &= ~KEY_FLAG_UPLOADED_TO_HARDWARE;
163 164
164 if (!(key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_MMIC)) 165 if (!((key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_MMIC) ||
166 (key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_IV)))
165 key->local->crypto_tx_tailroom_needed_cnt++; 167 key->local->crypto_tx_tailroom_needed_cnt++;
166} 168}
167 169