summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsam <sam@FreeBSD.org>2009-02-24 00:03:14 +0000
committersam <sam@FreeBSD.org>2009-02-24 00:03:14 +0000
commit0c3d0ae510aa78ad003ce1f556f09cde368067a8 (patch)
treea97c725bfbd786c387a28b3888d4bf42f149fac7
parent9b20a16012125ff8adb90a860f91e436bea39556 (diff)
downloadFreeBSD-src-0c3d0ae510aa78ad003ce1f556f09cde368067a8.zip
FreeBSD-src-0c3d0ae510aa78ad003ce1f556f09cde368067a8.tar.gz
move eeprom attach above first reset as the reset code checks the
eeprom contents for 9280 and later parts
-rw-r--r--sys/dev/ath/ath_hal/ar5416/ar5416_attach.c8
-rw-r--r--sys/dev/ath/ath_hal/ar5416/ar9160_attach.c8
2 files changed, 8 insertions, 8 deletions
diff --git a/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c b/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c
index 8fccbd1..233b0da 100644
--- a/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c
+++ b/sys/dev/ath/ath_hal/ar5416/ar5416_attach.c
@@ -244,6 +244,10 @@ ar5416Attach(uint16_t devid, HAL_SOFTC sc,
HAL_INI_VAL((struct ini *)&AH5416(ah)->ah_ini_addac, 31, 1) = 0;
}
+ ecode = ath_hal_v14EepromAttach(ah);
+ if (ecode != HAL_OK)
+ goto bad;
+
if (!ar5416ChipReset(ah, AH_NULL)) { /* reset chip */
HALDEBUG(ah, HAL_DEBUG_ANY, "%s: chip reset failed\n",
__func__);
@@ -297,10 +301,6 @@ ar5416Attach(uint16_t devid, HAL_SOFTC sc,
#endif
}
- ecode = ath_hal_v14EepromAttach(ah);
- if (ecode != HAL_OK)
- goto bad;
-
/*
* Got everything we need now to setup the capabilities.
*/
diff --git a/sys/dev/ath/ath_hal/ar5416/ar9160_attach.c b/sys/dev/ath/ath_hal/ar5416/ar9160_attach.c
index b7f7166..14e8d56 100644
--- a/sys/dev/ath/ath_hal/ar5416/ar9160_attach.c
+++ b/sys/dev/ath/ath_hal/ar5416/ar9160_attach.c
@@ -166,6 +166,10 @@ ar9160Attach(uint16_t devid, HAL_SOFTC sc,
else
HAL_INI_INIT(&AH5416(ah)->ah_ini_addac, ar9160Addac, 2);
+ ecode = ath_hal_v14EepromAttach(ah);
+ if (ecode != HAL_OK)
+ goto bad;
+
if (!ar5416ChipReset(ah, AH_NULL)) { /* reset chip */
HALDEBUG(ah, HAL_DEBUG_ANY, "%s: chip reset failed\n", __func__);
ecode = HAL_EIO;
@@ -217,10 +221,6 @@ ar9160Attach(uint16_t devid, HAL_SOFTC sc,
goto bad;
}
- ecode = ath_hal_v14EepromAttach(ah);
- if (ecode != HAL_OK)
- goto bad;
-
/*
* Got everything we need now to setup the capabilities.
*/
OpenPOWER on IntegriCloud