diff options
Diffstat (limited to 'drivers/net/wireless/ath5k/eeprom.c')
-rw-r--r-- | drivers/net/wireless/ath5k/eeprom.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath5k/eeprom.c b/drivers/net/wireless/ath5k/eeprom.c index b4ec539c464b..a54ee7e4967b 100644 --- a/drivers/net/wireless/ath5k/eeprom.c +++ b/drivers/net/wireless/ath5k/eeprom.c | |||
@@ -204,7 +204,7 @@ static int ath5k_eeprom_read_ants(struct ath5k_hw *ah, u32 *offset, | |||
204 | 204 | ||
205 | /* Get antenna modes */ | 205 | /* Get antenna modes */ |
206 | ah->ah_antenna[mode][0] = | 206 | ah->ah_antenna[mode][0] = |
207 | (ee->ee_ant_control[mode][0] << 4) | 0x1; | 207 | (ee->ee_ant_control[mode][0] << 4); |
208 | ah->ah_antenna[mode][AR5K_ANT_FIXED_A] = | 208 | ah->ah_antenna[mode][AR5K_ANT_FIXED_A] = |
209 | ee->ee_ant_control[mode][1] | | 209 | ee->ee_ant_control[mode][1] | |
210 | (ee->ee_ant_control[mode][2] << 6) | | 210 | (ee->ee_ant_control[mode][2] << 6) | |
@@ -517,9 +517,9 @@ ath5k_eeprom_init_modes(struct ath5k_hw *ah) | |||
517 | static inline void | 517 | static inline void |
518 | ath5k_get_pcdac_intercepts(struct ath5k_hw *ah, u8 min, u8 max, u8 *vp) | 518 | ath5k_get_pcdac_intercepts(struct ath5k_hw *ah, u8 min, u8 max, u8 *vp) |
519 | { | 519 | { |
520 | const static u16 intercepts3[] = | 520 | static const u16 intercepts3[] = |
521 | { 0, 5, 10, 20, 30, 50, 70, 85, 90, 95, 100 }; | 521 | { 0, 5, 10, 20, 30, 50, 70, 85, 90, 95, 100 }; |
522 | const static u16 intercepts3_2[] = | 522 | static const u16 intercepts3_2[] = |
523 | { 0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100 }; | 523 | { 0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100 }; |
524 | const u16 *ip; | 524 | const u16 *ip; |
525 | int i; | 525 | int i; |
@@ -1412,6 +1412,7 @@ ath5k_eeprom_init(struct ath5k_hw *ah) | |||
1412 | 1412 | ||
1413 | return 0; | 1413 | return 0; |
1414 | } | 1414 | } |
1415 | |||
1415 | /* | 1416 | /* |
1416 | * Read the MAC address from eeprom | 1417 | * Read the MAC address from eeprom |
1417 | */ | 1418 | */ |
@@ -1448,3 +1449,14 @@ int ath5k_eeprom_read_mac(struct ath5k_hw *ah, u8 *mac) | |||
1448 | return 0; | 1449 | return 0; |
1449 | } | 1450 | } |
1450 | 1451 | ||
1452 | bool ath5k_eeprom_is_hb63(struct ath5k_hw *ah) | ||
1453 | { | ||
1454 | u16 data; | ||
1455 | |||
1456 | ath5k_hw_eeprom_read(ah, AR5K_EEPROM_IS_HB63, &data); | ||
1457 | |||
1458 | if ((ah->ah_mac_version == (AR5K_SREV_AR2425 >> 4)) && data) | ||
1459 | return true; | ||
1460 | else | ||
1461 | return false; | ||
1462 | } | ||