diff options
author | Jouni Malinen <jouni.malinen@atheros.com> | 2009-03-02 11:15:53 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-03-05 14:39:38 -0500 |
commit | e0caf9eaae5182ab4e02a5d703ade64719738f87 (patch) | |
tree | 7009cf60091d2c403ac4479044c2da067ce8a3ab /drivers/net/wireless/ath9k/hw.c | |
parent | 672903b329579ff43ae3d553cf55bd82041921c1 (diff) |
ath9k: Remove unused key xoring
This is not used anywhere in ath9k and is just making the code more
confusing.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/hw.c')
-rw-r--r-- | drivers/net/wireless/ath9k/hw.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/drivers/net/wireless/ath9k/hw.c b/drivers/net/wireless/ath9k/hw.c index 5672f43e58e2..c8929edfe9d6 100644 --- a/drivers/net/wireless/ath9k/hw.c +++ b/drivers/net/wireless/ath9k/hw.c | |||
@@ -2415,14 +2415,11 @@ bool ath9k_hw_keysetmac(struct ath_hw *ah, u16 entry, const u8 *mac) | |||
2415 | 2415 | ||
2416 | bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | 2416 | bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, |
2417 | const struct ath9k_keyval *k, | 2417 | const struct ath9k_keyval *k, |
2418 | const u8 *mac, int xorKey) | 2418 | const u8 *mac) |
2419 | { | 2419 | { |
2420 | const struct ath9k_hw_capabilities *pCap = &ah->caps; | 2420 | const struct ath9k_hw_capabilities *pCap = &ah->caps; |
2421 | u32 key0, key1, key2, key3, key4; | 2421 | u32 key0, key1, key2, key3, key4; |
2422 | u32 keyType; | 2422 | u32 keyType; |
2423 | u32 xorMask = xorKey ? | ||
2424 | (ATH9K_KEY_XOR << 24 | ATH9K_KEY_XOR << 16 | ATH9K_KEY_XOR << 8 | ||
2425 | | ATH9K_KEY_XOR) : 0; | ||
2426 | 2423 | ||
2427 | if (entry >= pCap->keycache_size) { | 2424 | if (entry >= pCap->keycache_size) { |
2428 | DPRINTF(ah->ah_sc, ATH_DBG_KEYCACHE, | 2425 | DPRINTF(ah->ah_sc, ATH_DBG_KEYCACHE, |
@@ -2474,11 +2471,11 @@ bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | |||
2474 | return false; | 2471 | return false; |
2475 | } | 2472 | } |
2476 | 2473 | ||
2477 | key0 = get_unaligned_le32(k->kv_val + 0) ^ xorMask; | 2474 | key0 = get_unaligned_le32(k->kv_val + 0); |
2478 | key1 = (get_unaligned_le16(k->kv_val + 4) ^ xorMask) & 0xffff; | 2475 | key1 = get_unaligned_le16(k->kv_val + 4); |
2479 | key2 = get_unaligned_le32(k->kv_val + 6) ^ xorMask; | 2476 | key2 = get_unaligned_le32(k->kv_val + 6); |
2480 | key3 = (get_unaligned_le16(k->kv_val + 10) ^ xorMask) & 0xffff; | 2477 | key3 = get_unaligned_le16(k->kv_val + 10); |
2481 | key4 = get_unaligned_le32(k->kv_val + 12) ^ xorMask; | 2478 | key4 = get_unaligned_le32(k->kv_val + 12); |
2482 | if (k->kv_len <= LEN_WEP104) | 2479 | if (k->kv_len <= LEN_WEP104) |
2483 | key4 &= 0xff; | 2480 | key4 &= 0xff; |
2484 | 2481 | ||