diff options
author | Wojciech Dubowik <dubowoj@neratec.com> | 2011-01-11 03:00:31 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-01-19 11:36:08 -0500 |
commit | fda9b7afa70f9003853929821748aec98d567b1e (patch) | |
tree | 168d1a800bc53c63bd59e1f780a66852502247c2 /drivers/net/wireless/ath/ath5k/pci.c | |
parent | 8b3f4616d40a2ad19dd14af40b73f56860c812ea (diff) |
ath5k: Fix return codes for eeprom read functions.
Eeprom read functions are of bool type and not int.
Signed-off-by: Wojciech Dubowik <Wojciech.Dubowik@neratec.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/pci.c')
-rw-r--r-- | drivers/net/wireless/ath/ath5k/pci.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/ath5k/pci.c b/drivers/net/wireless/ath/ath5k/pci.c index 7f8c5b0e9d2a..66598a0d1df0 100644 --- a/drivers/net/wireless/ath/ath5k/pci.c +++ b/drivers/net/wireless/ath/ath5k/pci.c | |||
@@ -69,7 +69,8 @@ static void ath5k_pci_read_cachesize(struct ath_common *common, int *csz) | |||
69 | /* | 69 | /* |
70 | * Read from eeprom | 70 | * Read from eeprom |
71 | */ | 71 | */ |
72 | bool ath5k_pci_eeprom_read(struct ath_common *common, u32 offset, u16 *data) | 72 | static bool |
73 | ath5k_pci_eeprom_read(struct ath_common *common, u32 offset, u16 *data) | ||
73 | { | 74 | { |
74 | struct ath5k_hw *ah = (struct ath5k_hw *) common->ah; | 75 | struct ath5k_hw *ah = (struct ath5k_hw *) common->ah; |
75 | u32 status, timeout; | 76 | u32 status, timeout; |
@@ -90,15 +91,15 @@ bool ath5k_pci_eeprom_read(struct ath_common *common, u32 offset, u16 *data) | |||
90 | status = ath5k_hw_reg_read(ah, AR5K_EEPROM_STATUS); | 91 | status = ath5k_hw_reg_read(ah, AR5K_EEPROM_STATUS); |
91 | if (status & AR5K_EEPROM_STAT_RDDONE) { | 92 | if (status & AR5K_EEPROM_STAT_RDDONE) { |
92 | if (status & AR5K_EEPROM_STAT_RDERR) | 93 | if (status & AR5K_EEPROM_STAT_RDERR) |
93 | return -EIO; | 94 | return false; |
94 | *data = (u16)(ath5k_hw_reg_read(ah, AR5K_EEPROM_DATA) & | 95 | *data = (u16)(ath5k_hw_reg_read(ah, AR5K_EEPROM_DATA) & |
95 | 0xffff); | 96 | 0xffff); |
96 | return 0; | 97 | return true; |
97 | } | 98 | } |
98 | udelay(15); | 99 | udelay(15); |
99 | } | 100 | } |
100 | 101 | ||
101 | return -ETIMEDOUT; | 102 | return false; |
102 | } | 103 | } |
103 | 104 | ||
104 | int ath5k_hw_read_srev(struct ath5k_hw *ah) | 105 | int ath5k_hw_read_srev(struct ath5k_hw *ah) |