From 9f098ac76fb27da832d609b7e572fe98cf405e49 Mon Sep 17 00:00:00 2001 From: Adrian Chadd Date: Wed, 23 Apr 2014 22:43:39 +0000 Subject: [PATCH] Allow the state of the interface to be "up" if the VAP is in SLEEP state. Without this, the carrier will drop when the NIC transitions to SLEEP and nothing will ever transmit. --- sys/net80211/ieee80211.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c index 6ba0984cd136..538a873ad0be 100644 --- a/sys/net80211/ieee80211.c +++ b/sys/net80211/ieee80211.c @@ -1408,7 +1408,8 @@ ieee80211_media_status(struct ifnet *ifp, struct ifmediareq *imr) * rate only when running; otherwise we may have a mismatch * in which case the rate will not be convertible. */ - if (vap->iv_state == IEEE80211_S_RUN) { + if (vap->iv_state == IEEE80211_S_RUN || + vap->iv_state == IEEE80211_S_SLEEP) { imr->ifm_status |= IFM_ACTIVE; mode = ieee80211_chan2mode(ic->ic_curchan); } else