diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath/ar9170/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath5k/pcu.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/b43/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00crypto.c | 2 |
5 files changed, 9 insertions, 9 deletions
diff --git a/drivers/net/wireless/ath/ar9170/main.c b/drivers/net/wireless/ath/ar9170/main.c index 4ef1d2fc859c..99df9ddae9cb 100644 --- a/drivers/net/wireless/ath/ar9170/main.c +++ b/drivers/net/wireless/ath/ar9170/main.c | |||
@@ -1555,7 +1555,7 @@ static int ar9170_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, | |||
1555 | 1555 | ||
1556 | switch (key->alg) { | 1556 | switch (key->alg) { |
1557 | case ALG_WEP: | 1557 | case ALG_WEP: |
1558 | if (key->keylen == LEN_WEP40) | 1558 | if (key->keylen == WLAN_KEY_LEN_WEP40) |
1559 | ktype = AR9170_ENC_ALG_WEP64; | 1559 | ktype = AR9170_ENC_ALG_WEP64; |
1560 | else | 1560 | else |
1561 | ktype = AR9170_ENC_ALG_WEP128; | 1561 | ktype = AR9170_ENC_ALG_WEP128; |
diff --git a/drivers/net/wireless/ath/ath5k/pcu.c b/drivers/net/wireless/ath/ath5k/pcu.c index 579aa0a96ab8..ec35503f6a40 100644 --- a/drivers/net/wireless/ath/ath5k/pcu.c +++ b/drivers/net/wireless/ath/ath5k/pcu.c | |||
@@ -1038,9 +1038,9 @@ int ath5k_keycache_type(const struct ieee80211_key_conf *key) | |||
1038 | case ALG_CCMP: | 1038 | case ALG_CCMP: |
1039 | return AR5K_KEYTABLE_TYPE_CCM; | 1039 | return AR5K_KEYTABLE_TYPE_CCM; |
1040 | case ALG_WEP: | 1040 | case ALG_WEP: |
1041 | if (key->keylen == LEN_WEP40) | 1041 | if (key->keylen == WLAN_KEY_LEN_WEP40) |
1042 | return AR5K_KEYTABLE_TYPE_40; | 1042 | return AR5K_KEYTABLE_TYPE_40; |
1043 | else if (key->keylen == LEN_WEP104) | 1043 | else if (key->keylen == WLAN_KEY_LEN_WEP104) |
1044 | return AR5K_KEYTABLE_TYPE_104; | 1044 | return AR5K_KEYTABLE_TYPE_104; |
1045 | return -EINVAL; | 1045 | return -EINVAL; |
1046 | default: | 1046 | default: |
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 4acfab514916..1579c9407ed5 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -2472,14 +2472,14 @@ bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | |||
2472 | } | 2472 | } |
2473 | break; | 2473 | break; |
2474 | case ATH9K_CIPHER_WEP: | 2474 | case ATH9K_CIPHER_WEP: |
2475 | if (k->kv_len < LEN_WEP40) { | 2475 | if (k->kv_len < WLAN_KEY_LEN_WEP40) { |
2476 | DPRINTF(ah->ah_sc, ATH_DBG_ANY, | 2476 | DPRINTF(ah->ah_sc, ATH_DBG_ANY, |
2477 | "WEP key length %u too small\n", k->kv_len); | 2477 | "WEP key length %u too small\n", k->kv_len); |
2478 | return false; | 2478 | return false; |
2479 | } | 2479 | } |
2480 | if (k->kv_len <= LEN_WEP40) | 2480 | if (k->kv_len <= WLAN_KEY_LEN_WEP40) |
2481 | keyType = AR_KEYTABLE_TYPE_40; | 2481 | keyType = AR_KEYTABLE_TYPE_40; |
2482 | else if (k->kv_len <= LEN_WEP104) | 2482 | else if (k->kv_len <= WLAN_KEY_LEN_WEP104) |
2483 | keyType = AR_KEYTABLE_TYPE_104; | 2483 | keyType = AR_KEYTABLE_TYPE_104; |
2484 | else | 2484 | else |
2485 | keyType = AR_KEYTABLE_TYPE_128; | 2485 | keyType = AR_KEYTABLE_TYPE_128; |
@@ -2498,7 +2498,7 @@ bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | |||
2498 | key2 = get_unaligned_le32(k->kv_val + 6); | 2498 | key2 = get_unaligned_le32(k->kv_val + 6); |
2499 | key3 = get_unaligned_le16(k->kv_val + 10); | 2499 | key3 = get_unaligned_le16(k->kv_val + 10); |
2500 | key4 = get_unaligned_le32(k->kv_val + 12); | 2500 | key4 = get_unaligned_le32(k->kv_val + 12); |
2501 | if (k->kv_len <= LEN_WEP104) | 2501 | if (k->kv_len <= WLAN_KEY_LEN_WEP104) |
2502 | key4 &= 0xff; | 2502 | key4 &= 0xff; |
2503 | 2503 | ||
2504 | /* | 2504 | /* |
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index ec8516eadc4f..cb4a8712946a 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c | |||
@@ -3637,7 +3637,7 @@ static int b43_op_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, | |||
3637 | err = -EINVAL; | 3637 | err = -EINVAL; |
3638 | switch (key->alg) { | 3638 | switch (key->alg) { |
3639 | case ALG_WEP: | 3639 | case ALG_WEP: |
3640 | if (key->keylen == LEN_WEP40) | 3640 | if (key->keylen == WLAN_KEY_LEN_WEP40) |
3641 | algorithm = B43_SEC_ALGO_WEP40; | 3641 | algorithm = B43_SEC_ALGO_WEP40; |
3642 | else | 3642 | else |
3643 | algorithm = B43_SEC_ALGO_WEP104; | 3643 | algorithm = B43_SEC_ALGO_WEP104; |
diff --git a/drivers/net/wireless/rt2x00/rt2x00crypto.c b/drivers/net/wireless/rt2x00/rt2x00crypto.c index 57ab42cfed34..bc4e81e21841 100644 --- a/drivers/net/wireless/rt2x00/rt2x00crypto.c +++ b/drivers/net/wireless/rt2x00/rt2x00crypto.c | |||
@@ -33,7 +33,7 @@ enum cipher rt2x00crypto_key_to_cipher(struct ieee80211_key_conf *key) | |||
33 | { | 33 | { |
34 | switch (key->alg) { | 34 | switch (key->alg) { |
35 | case ALG_WEP: | 35 | case ALG_WEP: |
36 | if (key->keylen == LEN_WEP40) | 36 | if (key->keylen == WLAN_KEY_LEN_WEP40) |
37 | return CIPHER_WEP64; | 37 | return CIPHER_WEP64; |
38 | else | 38 | else |
39 | return CIPHER_WEP128; | 39 | return CIPHER_WEP128; |