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:
Andriy Voskoboinyk 2015-11-30 17:16:51 +00:00
parent e53ea2ab77
commit 54b27b3583
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=291493

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);