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

Commit 40346b66 authored by Luis R. Rodriguez's avatar Luis R. Rodriguez Committed by John W. Linville
Browse files

ath9k_hw: inform ANI calibration when scanning



The new ANI implementation will use this to skip ANI
calibration upon a scan. This cannot be ported to the
older ANI implementation unless default ANI values from
the ANI are also used upon a scan. This is essentially
what one of the things thenew ANI does.

Signed-off-by: default avatarLuis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 7ca710d5
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -322,7 +322,7 @@ static int32_t ath9k_hw_ani_get_listen_time(struct ath_hw *ah)
	return listenTime;
}

static void ath9k_ani_reset_old(struct ath_hw *ah)
static void ath9k_ani_reset_old(struct ath_hw *ah, bool is_scanning)
{
	struct ar5416AniState *aniState;
	struct ath9k_channel *chan = ah->curchan;
+1 −1
Original line number Diff line number Diff line
@@ -416,7 +416,7 @@ void ath9k_host_rx_init(struct ath9k_htc_priv *priv)
{
	ath9k_hw_rxena(priv->ah);
	ath9k_htc_opmode_init(priv);
	ath9k_hw_startpcureceive(priv->ah);
	ath9k_hw_startpcureceive(priv->ah, (priv->op_flags & OP_SCANNING));
	priv->rx.last_rssi = ATH_RSSI_DUMMY_MARKER;
}

+2 −2
Original line number Diff line number Diff line
@@ -288,9 +288,9 @@ static inline bool ath9k_hw_iscal_supported(struct ath_hw *ah,
	return ath9k_hw_private_ops(ah)->iscal_supported(ah, calType);
}

static inline void ath9k_ani_reset(struct ath_hw *ah)
static inline void ath9k_ani_reset(struct ath_hw *ah, bool is_scanning)
{
	ath9k_hw_private_ops(ah)->ani_reset(ah);
	ath9k_hw_private_ops(ah)->ani_reset(ah, is_scanning);
}

#endif /* ATH9K_HW_OPS_H */
+1 −1
Original line number Diff line number Diff line
@@ -565,7 +565,7 @@ struct ath_hw_private_ops {
	void (*loadnf)(struct ath_hw *ah, struct ath9k_channel *chan);

	/* ANI */
	void (*ani_reset)(struct ath_hw *ah);
	void (*ani_reset)(struct ath_hw *ah, bool is_scanning);
	void (*ani_lower_immunity)(struct ath_hw *ah);
};

+2 −2
Original line number Diff line number Diff line
@@ -757,11 +757,11 @@ void ath9k_hw_putrxbuf(struct ath_hw *ah, u32 rxdp)
}
EXPORT_SYMBOL(ath9k_hw_putrxbuf);

void ath9k_hw_startpcureceive(struct ath_hw *ah)
void ath9k_hw_startpcureceive(struct ath_hw *ah, bool is_scanning)
{
	ath9k_enable_mib_counters(ah);

	ath9k_ani_reset(ah);
	ath9k_ani_reset(ah, is_scanning);

	REG_CLR_BIT(ah, AR_DIAG_SW, (AR_DIAG_RX_DIS | AR_DIAG_RX_ABORT));
}
Loading