*/
sc->sc_hasveol = ath_hal_hasveol(ah);
+ /* Interference mitigation/ambient noise immunity (ANI).
+ * In modes other than HAL_M_STA, it causes receive sensitivity
+ * problems for OFDM. */
+ sc->sc_hasintmit = ath_hal_hasintmit(ah);
+
/* get mac address from hardware */
ath_hal_getmac(ah, ic->ic_myaddr);
if (sc->sc_hasbmask) {
if (sc->sc_softled)
ath_hal_gpioCfgOutput(ah, sc->sc_ledpin);
+
+ if ((sc->sc_opmode != HAL_M_STA) && sc->sc_hasintmit)
+ ath_hal_setintmit(ah, 0);
+
/*
* This is needed only to setup initial state
* but it's best done after a reset.
if (!ath_hal_reset(ah, sc->sc_opmode, &sc->sc_curchan, AH_TRUE, &status))
printk("%s: %s: unable to reset hardware: '%s' (HAL status %u)\n",
DEV_NAME(dev), __func__, ath_get_hal_status_desc(status), status);
+
+ if ((sc->sc_opmode != HAL_M_STA) && sc->sc_hasintmit)
+ ath_hal_setintmit(ah, 0);
+
ath_update_txpow(sc); /* update tx power state */
if (ath_startrecv(sc) != 0) /* restart recv */
printk("%s: %s: unable to start recv logic\n",
if (sc->sc_softled)
ath_hal_gpioCfgOutput(ah, sc->sc_ledpin);
+ if ((sc->sc_opmode != HAL_M_STA) && sc->sc_hasintmit)
+ ath_hal_setintmit(ah, 0);
+
sc->sc_curchan = hchan;
ath_update_txpow(sc); /* update tx power state */
return ath_hal_getcapability(ah, HAL_CAP_XR, 0, NULL) == HAL_OK;
}
+static inline HAL_BOOL ath_hal_hasintmit(struct ath_hal *ah)
+{
+ return (ath_hal_getcapability(ah, HAL_CAP_INTMIT, 0, NULL) == HAL_OK);
+}
+
+static inline HAL_BOOL ath_hal_getintmit(struct ath_hal *ah, u_int32_t *dst)
+{
+ return (ath_hal_getcapability(ah, HAL_CAP_INTMIT, 1, dst) == HAL_OK);
+}
+
+static inline HAL_BOOL ath_hal_setintmit(struct ath_hal *ah, u_int32_t v)
+{
+ return (ath_hal_setcapability(ah, HAL_CAP_INTMIT, 1, v, NULL) == HAL_OK);
+}
+
#endif /* #ifndef _IF_ATH_HAL_WRAPPERS_H_ */
sc_hasclrkey:1, /* CLR key supported */
sc_devstopped:1, /* stopped due to of no tx bufs */
sc_stagbeacons:1, /* use staggered beacons */
- sc_dfswait:1, /* waiting on channel for radar detect */
- sc_ackrate:1; /* send acks at high bitrate */
+ sc_dfswait:1, /* waiting on channel for radar detect */
+ sc_ackrate:1, /* send acks at high bitrate */
+ sc_hasintmit:1; /* Interference mitigation */
/* rate tables */
const HAL_RATE_TABLE *sc_rates[IEEE80211_MODE_MAX];
const HAL_RATE_TABLE *sc_currates; /* current rate table */