Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cfbed87b authored by Sujith Manoharan's avatar Sujith Manoharan Committed by Kalle Valo
Browse files

ath9k: Enable manual peak detect calibration



On some AR955x/QCA953x boards, noise floor calibration
gets stuck and the cause is a hardware/BB issue. To fix
this, peak detect calibration in the HW is disabled
and is done in the driver instead. There a few differences
with the calibration routine for older chips like
AR9331.

Signed-off-by: default avatarSujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent e4e292f3
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -1640,8 +1640,14 @@ static bool ar9003_hw_init_cal_soc(struct ath_hw *ah,

skip_tx_iqcal:
	if (run_agc_cal || !(ah->ah_flags & AH_FASTCC)) {
		if (AR_SREV_9330_11(ah))
			ar9003_hw_manual_peak_cal(ah, 0, IS_CHAN_2GHZ(chan));
		if (AR_SREV_9330_11(ah) || AR_SREV_9531(ah) || AR_SREV_9550(ah)) {
			for (i = 0; i < AR9300_MAX_CHAINS; i++) {
				if (!(ah->rxchainmask & (1 << i)))
					continue;
				ar9003_hw_manual_peak_cal(ah, i,
							  IS_CHAN_2GHZ(chan));
			}
		}

		/*
		 * For non-AR9550 chips, we just trigger AGC calibration