summaryrefslogtreecommitdiff
path: root/sys/net80211
diff options
context:
space:
mode:
authorSam Leffler <sam@FreeBSD.org>2009-07-24 15:37:02 +0000
committerSam Leffler <sam@FreeBSD.org>2009-07-24 15:37:02 +0000
commit8ed1835deaf8bb40d3860f06253fff7fa8fe332c (patch)
tree9db07d427a5f22a5d1b0f87382fde30668cfe38b /sys/net80211
parent2c4e7faeae8f0b3c555b72f76e3cb059257f620c (diff)
Notes
Diffstat (limited to 'sys/net80211')
-rw-r--r--sys/net80211/ieee80211_output.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/sys/net80211/ieee80211_output.c b/sys/net80211/ieee80211_output.c
index afbbfc36fa3f..f1a21bce8f2a 100644
--- a/sys/net80211/ieee80211_output.c
+++ b/sys/net80211/ieee80211_output.c
@@ -382,10 +382,22 @@ ieee80211_output(struct ifnet *ifp, struct mbuf *m,
{
#define senderr(e) do { error = (e); goto bad;} while (0)
struct ieee80211_node *ni = NULL;
- struct ieee80211vap *vap = ifp->if_softc;
+ struct ieee80211vap *vap;
struct ieee80211_frame *wh;
int error;
+ if (ifp->if_drv_flags & IFF_DRV_OACTIVE) {
+ /*
+ * Short-circuit requests if the vap is marked OACTIVE
+ * as this can happen because a packet came down through
+ * ieee80211_start before the vap entered RUN state in
+ * which case it's ok to just drop the frame. This
+ * should not be necessary but callers of if_output don't
+ * check OACTIVE.
+ */
+ senderr(ENETDOWN);
+ }
+ vap = ifp->if_softc;
/*
* Hand to the 802.3 code if not tagged as
* a raw 802.11 frame.