summaryrefslogtreecommitdiffstats
path: root/sys/dev/ath/ath_hal
diff options
context:
space:
mode:
authorrpaulo <rpaulo@FreeBSD.org>2010-05-29 16:10:07 +0000
committerrpaulo <rpaulo@FreeBSD.org>2010-05-29 16:10:07 +0000
commit5ba9bca748c58368609e4d5f6d1524aba8c613df (patch)
tree542789486ff8460368ce4aa717cfc142ea870971 /sys/dev/ath/ath_hal
parent1683756345e116457d5edc25e4956b3ee122327a (diff)
downloadFreeBSD-src-5ba9bca748c58368609e4d5f6d1524aba8c613df.zip
FreeBSD-src-5ba9bca748c58368609e4d5f6d1524aba8c613df.tar.gz
Don't shadow the global variable 'version'.
Submitted by: Arnaud Lacombe <alc@NetBSD.org> MFC after: 1 week
Diffstat (limited to 'sys/dev/ath/ath_hal')
-rw-r--r--sys/dev/ath/ath_hal/ah_eeprom_v1.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/dev/ath/ath_hal/ah_eeprom_v1.c b/sys/dev/ath/ath_hal/ah_eeprom_v1.c
index 0f9ed36..828b90b 100644
--- a/sys/dev/ath/ath_hal/ah_eeprom_v1.c
+++ b/sys/dev/ath/ath_hal/ah_eeprom_v1.c
@@ -112,7 +112,7 @@ ath_hal_v1EepromAttach(struct ath_hal *ah)
{
HAL_EEPROM_v1 *ee = AH_PRIVATE(ah)->ah_eeprom;
uint16_t athvals[AR_EEPROM_ATHEROS_MAX]; /* XXX off stack */
- uint16_t protect, version, eeval;
+ uint16_t protect, eeprom_version, eeval;
uint32_t sum;
int i, loc;
@@ -138,18 +138,18 @@ ath_hal_v1EepromAttach(struct ath_hal *ah)
HALDEBUG(ah, HAL_DEBUG_ATTACH, "EEPROM protect 0x%x\n", protect);
/* XXX check proper access before continuing */
- if (!ath_hal_eepromRead(ah, AR_EEPROM_VERSION, &version)) {
+ if (!ath_hal_eepromRead(ah, AR_EEPROM_VERSION, &eeprom_version)) {
HALDEBUG(ah, HAL_DEBUG_ANY,
"%s: unable to read EEPROM version\n", __func__);
return HAL_EEREAD;
}
- if (((version>>12) & 0xf) != 1) {
+ if (((eeprom_version>>12) & 0xf) != 1) {
/*
* This code only groks the version 1 EEPROM layout.
*/
HALDEBUG(ah, HAL_DEBUG_ANY,
"%s: unsupported EEPROM version 0x%x found\n",
- __func__, version);
+ __func__, eeprom_version);
return HAL_EEVERSION;
}
@@ -183,7 +183,7 @@ ath_hal_v1EepromAttach(struct ath_hal *ah)
return HAL_ENOMEM;
}
- ee->ee_version = version;
+ ee->ee_version = eeprom_version;
ee->ee_protect = protect;
ee->ee_antenna = athvals[2];
ee->ee_biasCurrents = athvals[3];
@@ -243,7 +243,7 @@ ath_hal_v1EepromAttach(struct ath_hal *ah)
}
AH_PRIVATE(ah)->ah_eeprom = ee;
- AH_PRIVATE(ah)->ah_eeversion = version;
+ AH_PRIVATE(ah)->ah_eeversion = eeprom_version;
AH_PRIVATE(ah)->ah_eepromDetach = v1EepromDetach;
AH_PRIVATE(ah)->ah_eepromGet = v1EepromGet;
AH_PRIVATE(ah)->ah_eepromSet = v1EepromSet;
OpenPOWER on IntegriCloud