From 9e7aab73cdf8776820c415eec923486b30b59ead Mon Sep 17 00:00:00 2001 From: Adrian Chadd Date: Sun, 15 Mar 2015 21:19:52 +0000 Subject: [PATCH] Use WPI_FILTER_BSS for checking current state. PR: kern/197143 Submitted by: Andriy Voskoboinyk --- sys/dev/wpi/if_wpi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/dev/wpi/if_wpi.c b/sys/dev/wpi/if_wpi.c index f81d58867ac4..f84a36f6d5da 100644 --- a/sys/dev/wpi/if_wpi.c +++ b/sys/dev/wpi/if_wpi.c @@ -1722,11 +1722,8 @@ static void wpi_calib_timeout(void *arg) { struct wpi_softc *sc = arg; - struct ifnet *ifp = sc->sc_ifp; - struct ieee80211com *ic = ifp->if_l2com; - struct ieee80211vap *vap = TAILQ_FIRST(&ic->ic_vaps); - if (vap->iv_state != IEEE80211_S_RUN) + if (!(sc->rxon.filter & htole32(WPI_FILTER_BSS))) return; wpi_power_calibration(sc);