wpi: ignore ic_update_promisc() call when device is not running

This change will fix kernel panic with uninitialized (zeroed)
RXON structure.

Tested with Intel 3945BG, IBSS mode.

Approved by:	adrian (mentor)
Differential Revision:	https://reviews.freebsd.org/D4304
This commit is contained in:
avos 2015-11-30 17:16:51 +00:00
parent 4a3bdaec00
commit 9c9c8e95ec

View File

@ -3556,6 +3556,13 @@ wpi_update_promisc(struct ieee80211com *ic)
{
struct wpi_softc *sc = ic->ic_softc;
WPI_LOCK(sc);
if (sc->sc_running == 0) {
WPI_UNLOCK(sc);
return;
}
WPI_UNLOCK(sc);
WPI_RXON_LOCK(sc);
wpi_set_promisc(sc);