]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r343340:
authoravos <avos@FreeBSD.org>
Mon, 28 Jan 2019 01:12:20 +0000 (01:12 +0000)
committeravos <avos@FreeBSD.org>
Mon, 28 Jan 2019 01:12:20 +0000 (01:12 +0000)
commit7636b2e7a915ebc45f723da14a34eeac73c05ef0
tree1a45b5c573b4ad698d9e1b4d0966dc412926fdd2
parentcf741ba484c92ba601b4be7d596d214a0e021386
MFC r343340:
net80211: fix channel list construction for non-auto operating mode.

Change the way how channel list mode <-> desired mode match is done:
- Match channel list mode for next non-auto desired modes:
 * 11b: 11g, 11ng;
 * 11a: 11na
- Add pre-defined channels only when one of the next conditions met:
 * the desired channel mode is 'auto' or
 * the desired channel and selected channel list modes are exactly
the same or
 * the previous rule (11g / 11n promotion) applies.

Before r275875 construction work properly for all except
11ng / 11na modes - these were broken at all
(i.e., the scan list was empty); after r275875 all checks were removed,
so scan table was populated by all device-compatible channels
(desired mode was ignored).

For example, if I will set 'ifconfig wlan0 mode 11ng' for RTL8821AU:
- pre-r275875: nothing, scan will not work;
- after r275875: both 11ng and 11na bands were scanned; also, since 11b
channel list was used, 14th channel was scanned too.
- after this change: only 11ng - 1-13 channels - are used for scanning.

Note: since 11-stable does not have VHT mode definitions
they were removed from this merge.
sys/net80211/ieee80211_scan_sta.c