Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src-draft/trunk]: src/sys/dev/pci Tweak scanning so that it only occurs once.



details:   https://anonhg.NetBSD.org/src-all/rev/456544c8b64c
branches:  trunk
changeset: 940892:456544c8b64c
user:      Nathanial Sloss <nat%netbsd.org@localhost>
date:      Wed Jul 01 12:25:26 2020 +1000

description:
Tweak scanning so that it only occurs once.

diffstat:

 sys/dev/pci/if_iwn.c |  6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diffs (23 lines):

diff -r 6f576fd8053e -r 456544c8b64c sys/dev/pci/if_iwn.c
--- a/sys/dev/pci/if_iwn.c      Tue Jun 23 01:26:02 2020 +1000
+++ b/sys/dev/pci/if_iwn.c      Wed Jul 01 12:25:26 2020 +1000
@@ -809,6 +809,10 @@
        
        ieee80211_scan_done(vap);
 
+       IEEE80211_LOCK(ic);
+       ieee80211_cancel_scan(vap);
+       IEEE80211_UNLOCK(ic);
+
        if (vap->iv_state == IEEE80211_S_RUN) {
                /* Set link LED to ON status if we are associated */
                iwn_set_led(sc, IWN_LED_LINK, 0, 1);
@@ -848,6 +852,8 @@
        struct ieee80211com *ic = vap->iv_ic;
        int error;
 
+       ss->ss_flags |= IEEE80211_SCAN_ONCE;
+
        error = iwn_scan(ic, ss);
        if (error != 0) {
                IEEE80211_LOCK(ic);



Home | Main Index | Thread Index | Old Index