mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-22 06:29:23 +01:00
station: constrain known frequencies before roam scan
The known frequency list may include frequencies that once were allowed but are now disabled due to regulatory restrictions. Don't include these frequencies in the roam scan.
This commit is contained in:
parent
887073b5d9
commit
ba6a48018c
@ -2656,12 +2656,17 @@ static int station_roam_scan_known_freqs(struct station *station)
|
|||||||
station->connected_network);
|
station->connected_network);
|
||||||
struct scan_freq_set *freqs = network_info_get_roam_frequencies(info,
|
struct scan_freq_set *freqs = network_info_get_roam_frequencies(info,
|
||||||
station->connected_bss->frequency, 5);
|
station->connected_bss->frequency, 5);
|
||||||
int r;
|
int r = -ENODATA;
|
||||||
|
|
||||||
if (!freqs)
|
if (!freqs)
|
||||||
return -ENODATA;
|
return r;
|
||||||
|
|
||||||
|
if (!wiphy_constrain_freq_set(station->wiphy, freqs))
|
||||||
|
goto free_set;
|
||||||
|
|
||||||
r = station_roam_scan(station, freqs);
|
r = station_roam_scan(station, freqs);
|
||||||
|
|
||||||
|
free_set:
|
||||||
scan_freq_set_free(freqs);
|
scan_freq_set_free(freqs);
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user