hostapd: DFS allow mixed channels

Allow mixed DFS and non-DFS channels, e.g., VHT160 on channels 36-64.
This is useful for testing VHT160 with mac80211_hwsim.

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com>
This commit is contained in:
Janusz Dziedzic 2014-02-15 19:37:21 +01:00 committed by Jouni Malinen
parent 4db216fcf7
commit b8058a69b0

View file

@ -296,6 +296,13 @@ static int dfs_check_chans_available(struct hostapd_iface *iface,
for(i = 0; i < n_chans; i++) { for(i = 0; i < n_chans; i++) {
channel = &mode->channels[start_chan_idx + i]; channel = &mode->channels[start_chan_idx + i];
if (channel->flag & HOSTAPD_CHAN_DISABLED)
break;
if (!(channel->flag & HOSTAPD_CHAN_RADAR))
continue;
if ((channel->flag & HOSTAPD_CHAN_DFS_MASK) != if ((channel->flag & HOSTAPD_CHAN_DFS_MASK) !=
HOSTAPD_CHAN_DFS_AVAILABLE) HOSTAPD_CHAN_DFS_AVAILABLE)
break; break;