aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexei Avshalom Lazar <ailizaro@codeaurora.org>2019-08-08 11:21:37 (GMT)
committerJouni Malinen <j@w1.fi>2019-09-13 13:14:17 (GMT)
commitdc6c3be4e2dd1c5d273f6deda4a2fbedbeaea193 (patch)
tree35c40dd51c9958e21a1cff152aa745949c5baed0
parent018edec9b2bd3db20605117c32ff79c1e625c432 (diff)
downloadhostap-dc6c3be4e2dd1c5d273f6deda4a2fbedbeaea193.zip
hostap-dc6c3be4e2dd1c5d273f6deda4a2fbedbeaea193.tar.gz
hostap-dc6c3be4e2dd1c5d273f6deda4a2fbedbeaea193.tar.bz2
wpa_supplicant: Add support for 60 GHz band channels 5 and 6
The previous support in the 60 GHz band was for channels 1-4. Add support for channels 5 and 6. Signed-off-by: Alexei Avshalom Lazar <ailizaro@codeaurora.org>
-rw-r--r--src/common/ieee802_11_common.c20
-rw-r--r--wpa_supplicant/config.c2
-rw-r--r--wpa_supplicant/wps_supplicant.c2
3 files changed, 12 insertions, 12 deletions
diff --git a/src/common/ieee802_11_common.c b/src/common/ieee802_11_common.c
index a081f87..f833ae8 100644
--- a/src/common/ieee802_11_common.c
+++ b/src/common/ieee802_11_common.c
@@ -871,8 +871,8 @@ enum hostapd_hw_mode ieee80211_freq_to_channel_ext(unsigned int freq,
return HOSTAPD_MODE_IEEE80211A;
}
- /* 56.16 GHz, channel 1..4 */
- if (freq >= 56160 + 2160 * 1 && freq <= 56160 + 2160 * 4) {
+ /* 56.16 GHz, channel 1..6 */
+ if (freq >= 56160 + 2160 * 1 && freq <= 56160 + 2160 * 6) {
if (sec_channel || vht)
return NUM_HOSTAPD_MODES;
@@ -991,8 +991,8 @@ static int ieee80211_chan_to_freq_us(u8 op_class, u8 chan)
if (chan < 149 || chan > 165)
return -1;
return 5000 + 5 * chan;
- case 34: /* 60 GHz band, channels 1..3 */
- if (chan < 1 || chan > 3)
+ case 34: /* 60 GHz band, channels 1..6 */
+ if (chan < 1 || chan > 6)
return -1;
return 56160 + 2160 * chan;
}
@@ -1029,8 +1029,8 @@ static int ieee80211_chan_to_freq_eu(u8 op_class, u8 chan)
if (chan < 149 || chan > 169)
return -1;
return 5000 + 5 * chan;
- case 18: /* 60 GHz band, channels 1..4 */
- if (chan < 1 || chan > 4)
+ case 18: /* 60 GHz band, channels 1..6 */
+ if (chan < 1 || chan > 6)
return -1;
return 56160 + 2160 * chan;
}
@@ -1073,8 +1073,8 @@ static int ieee80211_chan_to_freq_jp(u8 op_class, u8 chan)
if (chan < 100 || chan > 140)
return -1;
return 5000 + 5 * chan;
- case 59: /* 60 GHz band, channels 1..4 */
- if (chan < 1 || chan > 3)
+ case 59: /* 60 GHz band, channels 1..6 */
+ if (chan < 1 || chan > 6)
return -1;
return 56160 + 2160 * chan;
}
@@ -1161,8 +1161,8 @@ static int ieee80211_chan_to_freq_global(u8 op_class, u8 chan)
if (chan < 36 || chan > 128)
return -1;
return 5000 + 5 * chan;
- case 180: /* 60 GHz band, channels 1..4 */
- if (chan < 1 || chan > 4)
+ case 180: /* 60 GHz band, channels 1..6 */
+ if (chan < 1 || chan > 6)
return -1;
return 56160 + 2160 * chan;
}
diff --git a/wpa_supplicant/config.c b/wpa_supplicant/config.c
index d2ac01b..2f45bdf 100644
--- a/wpa_supplicant/config.c
+++ b/wpa_supplicant/config.c
@@ -2479,7 +2479,7 @@ static const struct parse_data ssid_fields[] = {
#endif /* CONFIG_OCV */
{ FUNC(peerkey) /* obsolete - removed */ },
{ INT_RANGE(mixed_cell, 0, 1) },
- { INT_RANGE(frequency, 0, 65000) },
+ { INT_RANGE(frequency, 0, 70200) },
{ INT_RANGE(fixed_freq, 0, 1) },
#ifdef CONFIG_ACS
{ INT_RANGE(acs, 0, 1) },
diff --git a/wpa_supplicant/wps_supplicant.c b/wpa_supplicant/wps_supplicant.c
index 1dd69a2..6b03634 100644
--- a/wpa_supplicant/wps_supplicant.c
+++ b/wpa_supplicant/wps_supplicant.c
@@ -2689,7 +2689,7 @@ static int wpas_wps_nfc_rx_handover_sel(struct wpa_supplicant *wpa_s,
(attr.rf_bands == NULL ||
*attr.rf_bands & WPS_RF_50GHZ))
freq = 5000 + 5 * chan;
- else if (chan >= 1 && chan <= 4 &&
+ else if (chan >= 1 && chan <= 6 &&
(attr.rf_bands == NULL ||
*attr.rf_bands & WPS_RF_60GHZ))
freq = 56160 + 2160 * chan;