wifi: fix the ranges of 5 GHz and 6 GHz bands

The 6 GHz band starts from frequency 5950, anything below is 5 GHz.
This commit is contained in:
Beniamino Galvani 2024-03-22 10:05:33 +01:00
parent 9ac1d6e22b
commit 8ca7433a14

View File

@ -698,9 +698,9 @@ nl80211_wiphy_info_handler(const struct nl_msg *msg, void *arg)
if (f->freq >= 2401 && f->freq <= 2495)
info->caps |= _NM_WIFI_DEVICE_CAP_FREQ_2GHZ;
if (f->freq >= 5150 && f->freq <= 5895)
if (f->freq >= 5150 && f->freq < 5950)
info->caps |= _NM_WIFI_DEVICE_CAP_FREQ_5GHZ;
if (f->freq >= 5925 && f->freq <= 7125)
if (f->freq >= 5950 && f->freq <= 7125)
info->caps |= _NM_WIFI_DEVICE_CAP_FREQ_6GHZ;
info->num_freqs++;