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/c71b59cb4dd0
branches:  trunk
changeset: 947359:c71b59cb4dd0
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 b0ee9589197c -r c71b59cb4dd0 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