[ath] listen to all beacons in IBSS and software beacon miss.

I added MYBEACON support a while ago to listen to beacons that are only
for your configured BSSID.  For AR9380 and later NICs this results in
a lot less chip wakeups in station mode as it then only shows you beacons
that are destined to you.

However in IBSS mode you really do want to hear all beacons so you can do
IBSS merges.  Oops.

So only use MYBEACON for STA + not-scanning, and just use BEACON for
the other modes it used to use BEACON for.

This doesn't completely fix IBSS merges though - there are still some
conditions to chase down and fix.
This commit is contained in:
Adrian Chadd 2015-11-25 18:24:49 +00:00
parent 75426752f5
commit 94a88508a5
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=291304

View file

@ -172,9 +172,14 @@ ath_calcrxfilter(struct ath_softc *sc)
*
* Otherwise we only really need to hear beacons from
* our own BSSID.
*
* IBSS? software beacon miss? Just receive all beacons.
* We need to hear beacons/probe requests from everyone so
* we can merge ibss.
*/
if (ic->ic_opmode == IEEE80211_M_STA ||
ic->ic_opmode == IEEE80211_M_IBSS || sc->sc_swbmiss) {
if (ic->ic_opmode == IEEE80211_M_IBSS || sc->sc_swbmiss) {
rfilt |= HAL_RX_FILTER_BEACON;
} else if (ic->ic_opmode == IEEE80211_M_STA) {
if (sc->sc_do_mybeacon && ! sc->sc_scanning) {
rfilt |= HAL_RX_FILTER_MYBEACON;
} else { /* scanning, non-mybeacon chips */
@ -431,7 +436,6 @@ ath_recv_mgmt(struct ieee80211_node *ni, struct mbuf *m,
sc->sc_syncbeacon = 0;
}
/* fall thru... */
case IEEE80211_FC0_SUBTYPE_PROBE_RESP:
if (vap->iv_opmode == IEEE80211_M_IBSS &&