When doing a scan while being associated it is possible that the scan

is deferred for the time it takes to flush the TX queue. This work being
done the scan then is continued, but only if it is marked to do so. As
the 'ifconfig scan' request is meant to be used after the interface is
brought up, request a background scan by default. This behaviour is
already documented in manual page.

This fixes on possible case where 'ifconfig scan' hangs infinitely.

MFC after:	1 month
This commit is contained in:
Bernhard Schmidt 2011-01-30 13:17:45 +00:00
parent 04a47f762d
commit a272741053
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=218090

View File

@ -3222,6 +3222,7 @@ scan_and_wait(int s)
memset(&sr, 0, sizeof(sr));
sr.sr_flags = IEEE80211_IOC_SCAN_ACTIVE
| IEEE80211_IOC_SCAN_BGSCAN
| IEEE80211_IOC_SCAN_NOPICK
| IEEE80211_IOC_SCAN_ONCE;
sr.sr_duration = IEEE80211_IOC_SCAN_FOREVER;