summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoradrian <adrian@FreeBSD.org>2011-03-11 04:31:00 +0000
committeradrian <adrian@FreeBSD.org>2011-03-11 04:31:00 +0000
commitd268e58dd43207d9af61a36e076fae3fa4069bd6 (patch)
tree82ae808aa9f41d2bfa2283d4132425f715ccb0c8
parent9e1a2538525a98612a880c76e416333d82508d26 (diff)
downloadFreeBSD-src-d268e58dd43207d9af61a36e076fae3fa4069bd6.zip
FreeBSD-src-d268e58dd43207d9af61a36e076fae3fa4069bd6.tar.gz
Bring over the same fix from the AR5416 PDADC calibration code.
The ath9k driver has a unified boundary/pdadc function, whereas ours is split into two (one for each EEPROM type.) This is why the AR9280 check is done here where we could safely assume it'll always be AR9280 or later.
-rw-r--r--sys/dev/ath/ath_hal/ar9002/ar9285_reset.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/ath/ath_hal/ar9002/ar9285_reset.c b/sys/dev/ath/ath_hal/ar9002/ar9285_reset.c
index 5d07005..2adbf2d 100644
--- a/sys/dev/ath/ath_hal/ar9002/ar9285_reset.c
+++ b/sys/dev/ath/ath_hal/ar9002/ar9285_reset.c
@@ -727,7 +727,10 @@ ar9285GetGainBoundariesAndPdadcs(struct ath_hal *ah,
/* Find starting index for this pdGain */
if (i == 0) {
- ss = 0; /* for the first pdGain, start from index 0 */
+ if (AR_SREV_MERLIN_20_OR_LATER(ah))
+ ss = (int16_t)(0 - (minPwrT4[i] / 2));
+ else
+ ss = 0; /* for the first pdGain, start from index 0 */
} else {
/* need overlap entries extrapolated below. */
ss = (int16_t)((pPdGainBoundaries[i-1] - (minPwrT4[i] / 2)) - tPdGainOverlap + 1 + minDelta);
OpenPOWER on IntegriCloud