Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 278853
b: refs/heads/master
c: a7e12c8
h: refs/heads/master
i:
  278851: 97754d7
v: v3
  • Loading branch information
Johannes Berg authored and Wey-Yi Guy committed Dec 2, 2011
1 parent d078683 commit 66fc960
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6b5a26f50a91fe46032f7ec8f5cd786c80dad34c
refs/heads/master: a7e12c8e229b89fa23469718b605bfdbe66962d7
5 changes: 0 additions & 5 deletions trunk/drivers/net/wireless/iwlwifi/iwl-agn-sta.c
Original file line number Diff line number Diff line change
Expand Up @@ -1250,9 +1250,6 @@ int iwl_set_dynamic_key(struct iwl_priv *priv,

switch (keyconf->cipher) {
case WLAN_CIPHER_SUITE_TKIP:
keyconf->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
keyconf->flags |= IEEE80211_KEY_FLAG_GENERATE_IV;

if (sta)
addr = sta->addr;
else /* station mode case only */
Expand All @@ -1265,8 +1262,6 @@ int iwl_set_dynamic_key(struct iwl_priv *priv,
seq.tkip.iv32, p1k, CMD_SYNC);
break;
case WLAN_CIPHER_SUITE_CCMP:
keyconf->flags |= IEEE80211_KEY_FLAG_GENERATE_IV;
/* fall through */
case WLAN_CIPHER_SUITE_WEP40:
case WLAN_CIPHER_SUITE_WEP104:
ret = iwlagn_send_sta_key(priv, keyconf, sta_id,
Expand Down
11 changes: 11 additions & 0 deletions trunk/drivers/net/wireless/iwlwifi/iwl-mac80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,17 @@ static int iwlagn_mac_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
return -EOPNOTSUPP;
}

switch (key->cipher) {
case WLAN_CIPHER_SUITE_TKIP:
key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
/* fall through */
case WLAN_CIPHER_SUITE_CCMP:
key->flags |= IEEE80211_KEY_FLAG_GENERATE_IV;
break;
default:
break;
}

/*
* We could program these keys into the hardware as well, but we
* don't expect much multicast traffic in IBSS and having keys
Expand Down

0 comments on commit 66fc960

Please sign in to comment.