aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-09-10 13:57:00 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-10-07 16:39:26 -0400
commit394317fc793eb25dbbda4432d29d97cd80f3b561 (patch)
tree176773d060e3412f82fd0d8e6e5b3d8fd0041663 /drivers/net/wireless
parent954fecea5d1df4d1dc7bf9a822a2fad308e8588e (diff)
ath5k: initialize eeprom struct early on attach
This fixes this sparse warning: CHECK drivers/net/wireless/ath/ath5k/attach.c drivers/net/wireless/ath/ath5k/attach.c:288:42: warning: symbol 'ee' shadows an earlier one drivers/net/wireless/ath/ath5k/attach.c:109:34: originally declared here Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/ath/ath5k/attach.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath5k/attach.c b/drivers/net/wireless/ath/ath5k/attach.c
index 2d262c7d9061..123612a8a5c6 100644
--- a/drivers/net/wireless/ath/ath5k/attach.c
+++ b/drivers/net/wireless/ath/ath5k/attach.c
@@ -281,12 +281,12 @@ struct ath5k_hw *ath5k_hw_attach(struct ath5k_softc *sc)
281 goto err_free; 281 goto err_free;
282 } 282 }
283 283
284 ee = &ah->ah_capabilities.cap_eeprom;
285
284 /* 286 /*
285 * Write PCI-E power save settings 287 * Write PCI-E power save settings
286 */ 288 */
287 if ((ah->ah_version == AR5K_AR5212) && (pdev->is_pcie)) { 289 if ((ah->ah_version == AR5K_AR5212) && (pdev->is_pcie)) {
288 struct ath5k_eeprom_info *ee = &ah->ah_capabilities.cap_eeprom;
289
290 ath5k_hw_reg_write(ah, 0x9248fc00, AR5K_PCIE_SERDES); 290 ath5k_hw_reg_write(ah, 0x9248fc00, AR5K_PCIE_SERDES);
291 ath5k_hw_reg_write(ah, 0x24924924, AR5K_PCIE_SERDES); 291 ath5k_hw_reg_write(ah, 0x24924924, AR5K_PCIE_SERDES);
292 292
@@ -324,7 +324,6 @@ struct ath5k_hw *ath5k_hw_attach(struct ath5k_softc *sc)
324 } 324 }
325 325
326 /* Crypto settings */ 326 /* Crypto settings */
327 ee = &ah->ah_capabilities.cap_eeprom;
328 ah->ah_aes_support = srev >= AR5K_SREV_AR5212_V4 && 327 ah->ah_aes_support = srev >= AR5K_SREV_AR5212_V4 &&
329 (ee->ee_version >= AR5K_EEPROM_VERSION_5_0 && 328 (ee->ee_version >= AR5K_EEPROM_VERSION_5_0 &&
330 !AR5K_EEPROM_AES_DIS(ee->ee_misc5)); 329 !AR5K_EEPROM_AES_DIS(ee->ee_misc5));