diff options
author | adrian <adrian@FreeBSD.org> | 2011-05-11 11:02:20 +0000 |
---|---|---|
committer | adrian <adrian@FreeBSD.org> | 2011-05-11 11:02:20 +0000 |
commit | 73e0979e8abe16a5c320dafa70aa6431e22daeb8 (patch) | |
tree | 8b743cc9b20c0adf092bc0fc57fffca5f81f1b10 | |
parent | 04842bd6c06607dea409de37f95bd6e722b663f0 (diff) | |
download | FreeBSD-src-73e0979e8abe16a5c320dafa70aa6431e22daeb8.zip FreeBSD-src-73e0979e8abe16a5c320dafa70aa6431e22daeb8.tar.gz |
Remove the initial NF completion check.
This is taking quite a while for some people in some situations
(eg AR5418 in phk's Abusive Radio Environment).
Instead, the rest of the calibration related code should
ensure that a NF calibration has occured before reading NF
values and kicking off another NF calibration.
The channel should also likely be marked as "noisy" (CWINT)
if the NF calibration takes too long.
-rw-r--r-- | sys/dev/ath/ath_hal/ar5416/ar5416_cal.c | 26 |
1 files changed, 4 insertions, 22 deletions
diff --git a/sys/dev/ath/ath_hal/ar5416/ar5416_cal.c b/sys/dev/ath/ath_hal/ar5416/ar5416_cal.c index e546daf..d9f42da 100644 --- a/sys/dev/ath/ath_hal/ar5416/ar5416_cal.c +++ b/sys/dev/ath/ath_hal/ar5416/ar5416_cal.c @@ -264,31 +264,13 @@ ar5416InitCal(struct ath_hal *ah, const struct ieee80211_channel *chan) * triggered at the same time. */ OS_REG_SET_BIT(ah, AR_PHY_AGC_CONTROL, AR_PHY_AGC_CONTROL_NF); - /* - * This sometimes takes a -lot- longer than it should. - * Just give it a bit more time. - */ - for (i = 0; i < MAX_CAL_CHECK; i++) { - if (ar5212WaitNFCalComplete(ah, 10000)) - break; - HALDEBUG(ah, HAL_DEBUG_ANY, "%s: initial NF calibration did " - "not complete in time; noisy environment (pass %d)?\n", __func__, i); - } - /* - * Although periodic and NF calibrations shouldn't run concurrently, - * this was causing the radio to not be usable on the active - * channel if the channel was busy. - * - * Instead, now simply print a warning and continue. That way if users - * report "weird crap", they should get this warning. + * This may take a while to run; make sure subsequent + * calibration routines check that this has completed + * before reading the value and triggering a subsequent + * calibration. */ - if (i >= MAX_CAL_CHECK) { - ath_hal_printf(ah, "[ath] Warning - initial NF calibration did " - "not complete in time, noisy environment?\n"); - /* return AH_FALSE; */ - } /* Initialize list pointers */ cal->cal_list = cal->cal_last = cal->cal_curr = AH_NULL; |