summaryrefslogtreecommitdiff
path: root/sys/net80211
diff options
context:
space:
mode:
authorStefan Sperling <stsp@cvs.openbsd.org>2018-04-27 17:03:10 +0000
committerStefan Sperling <stsp@cvs.openbsd.org>2018-04-27 17:03:10 +0000
commit2a2ebcd9a4fc16f2f3f7d865715be9d35553d18c (patch)
tree05e5d87446c4bfd0d975b4983590f875bf4fabd0 /sys/net80211
parent396409d3f48b2b81d5bdeeec18d62fc6f8b48238 (diff)
If a wifi driver does not provide an ic_bgscan_start() function there is no
point in scheduling ic_bgscan_timeout() since this timeout will find that it has nothing to do. ok phessler pirofti
Diffstat (limited to 'sys/net80211')
-rw-r--r--sys/net80211/ieee80211_input.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/net80211/ieee80211_input.c b/sys/net80211/ieee80211_input.c
index 304c13c3444..8b437a8ebae 100644
--- a/sys/net80211/ieee80211_input.c
+++ b/sys/net80211/ieee80211_input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ieee80211_input.c,v 1.198 2017/12/12 15:57:11 stsp Exp $ */
+/* $OpenBSD: ieee80211_input.c,v 1.199 2018/04/27 17:03:09 stsp Exp $ */
/*-
* Copyright (c) 2001 Atsushi Onoe
@@ -268,7 +268,7 @@ ieee80211_input(struct ifnet *ifp, struct mbuf *m, struct ieee80211_node *ni,
ni->ni_rstamp = rxi->rxi_tstamp;
ni->ni_inact = 0;
- if (ic->ic_state == IEEE80211_S_RUN) {
+ if (ic->ic_state == IEEE80211_S_RUN && ic->ic_bgscan_start) {
/* Cancel or start background scan based on RSSI. */
if ((*ic->ic_node_checkrssi)(ic, ni))
timeout_del(&ic->ic_bgscan_timeout);