diff options
author | John W. Linville <linville@tuxdriver.com> | 2011-06-30 11:26:04 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-06-30 11:26:04 -0400 |
commit | 690b0cacb6dbbbcb06b76139ab65e1bf3f63e7f1 (patch) | |
tree | 9199b20addcd9167a210957ac477a284c6f9a73d /net | |
parent | 16adf5d07987d93675945f3cecf0e33706566005 (diff) | |
parent | a0b8de350be458b33248e48b2174d9af8a4c4798 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into for-davem
Diffstat (limited to 'net')
-rw-r--r-- | net/mac80211/wpa.c | 8 | ||||
-rw-r--r-- | net/wireless/nl80211.c | 3 |
2 files changed, 9 insertions, 2 deletions
diff --git a/net/mac80211/wpa.c b/net/mac80211/wpa.c index 9dc3b5f26e80..d91c1a26630d 100644 --- a/net/mac80211/wpa.c +++ b/net/mac80211/wpa.c | |||
@@ -154,7 +154,13 @@ update_iv: | |||
154 | return RX_CONTINUE; | 154 | return RX_CONTINUE; |
155 | 155 | ||
156 | mic_fail: | 156 | mic_fail: |
157 | mac80211_ev_michael_mic_failure(rx->sdata, rx->key->conf.keyidx, | 157 | /* |
158 | * In some cases the key can be unset - e.g. a multicast packet, in | ||
159 | * a driver that supports HW encryption. Send up the key idx only if | ||
160 | * the key is set. | ||
161 | */ | ||
162 | mac80211_ev_michael_mic_failure(rx->sdata, | ||
163 | rx->key ? rx->key->conf.keyidx : -1, | ||
158 | (void *) skb->data, NULL, GFP_ATOMIC); | 164 | (void *) skb->data, NULL, GFP_ATOMIC); |
159 | return RX_DROP_UNUSABLE; | 165 | return RX_DROP_UNUSABLE; |
160 | } | 166 | } |
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 98fa8eb6cc4b..f07602d7bf68 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c | |||
@@ -6463,7 +6463,8 @@ void nl80211_michael_mic_failure(struct cfg80211_registered_device *rdev, | |||
6463 | if (addr) | 6463 | if (addr) |
6464 | NLA_PUT(msg, NL80211_ATTR_MAC, ETH_ALEN, addr); | 6464 | NLA_PUT(msg, NL80211_ATTR_MAC, ETH_ALEN, addr); |
6465 | NLA_PUT_U32(msg, NL80211_ATTR_KEY_TYPE, key_type); | 6465 | NLA_PUT_U32(msg, NL80211_ATTR_KEY_TYPE, key_type); |
6466 | NLA_PUT_U8(msg, NL80211_ATTR_KEY_IDX, key_id); | 6466 | if (key_id != -1) |
6467 | NLA_PUT_U8(msg, NL80211_ATTR_KEY_IDX, key_id); | ||
6467 | if (tsc) | 6468 | if (tsc) |
6468 | NLA_PUT(msg, NL80211_ATTR_KEY_SEQ, 6, tsc); | 6469 | NLA_PUT(msg, NL80211_ATTR_KEY_SEQ, 6, tsc); |
6469 | 6470 | ||