]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - src/patches/hostapd/hostapd-2.8-noscan.patch
hostapd: Update to 2.8
[people/pmueller/ipfire-2.x.git] / src / patches / hostapd / hostapd-2.8-noscan.patch
CommitLineData
3f7cec61
MF
1diff U3 hostapd/config_file.c hostapd/config_file.c
2--- a/hostapd/config_file.c Sun Apr 21 09:10:22 2019
3+++ b/hostapd/config_file.c Sun Jun 9 01:08:21 2019
4@@ -3390,6 +3390,10 @@
5 bss->ieee80211w = 1;
6 #endif /* CONFIG_OCV */
d6d5999a
MF
7 #ifdef CONFIG_IEEE80211N
8+ } else if (os_strcmp(buf, "noscan") == 0) {
9+ conf->noscan = atoi(pos);
10+ } else if (os_strcmp(buf, "ht_coex") == 0) {
11+ conf->no_ht_coex = !atoi(pos);
12 } else if (os_strcmp(buf, "ieee80211n") == 0) {
13 conf->ieee80211n = atoi(pos);
14 } else if (os_strcmp(buf, "ht_capab") == 0) {
3f7cec61
MF
15diff U3 src/ap/ap_config.h src/ap/ap_config.h
16--- a/src/ap/ap_config.h Sun Apr 21 09:10:22 2019
17+++ b/src/ap/ap_config.h Sun Jun 9 01:06:42 2019
18@@ -801,6 +801,8 @@
19
20 int ht_op_mode_fixed;
21 u16 ht_capab;
22+ int noscan;
23+ int no_ht_coex;
24 int ieee80211n;
25 int secondary_channel;
26 int no_pri_sec_switch;
27diff U3 src/ap/hw_features.c src/ap/hw_features.c
28--- a/src/ap/hw_features.c Sun Apr 21 09:10:22 2019
29+++ b/src/ap/hw_features.c Sun Jun 9 01:09:41 2019
30@@ -477,7 +477,8 @@
d6d5999a
MF
31 int ret;
32
33 /* Check that HT40 is used and PRI / SEC switch is allowed */
34- if (!iface->conf->secondary_channel || iface->conf->no_pri_sec_switch)
35+ if (!iface->conf->secondary_channel || iface->conf->no_pri_sec_switch ||
36+ iface->conf->noscan)
37 return 0;
38
39 hostapd_set_state(iface, HAPD_IFACE_HT_SCAN);
3f7cec61
MF
40diff U3 src/ap/ieee802_11_ht.c src/ap/ieee802_11_ht.c
41--- a/src/ap/ieee802_11_ht.c Sun Apr 21 09:10:22 2019
42+++ b/src/ap/ieee802_11_ht.c Sun Jun 9 01:13:09 2019
d6d5999a
MF
43@@ -252,6 +252,9 @@
44 return;
45 }
46
47+ if (iface->conf->noscan || iface->conf->no_ht_coex)
48+ return;
49+
50 if (len < IEEE80211_HDRLEN + 2 + sizeof(*bc_ie)) {
51 wpa_printf(MSG_DEBUG,
52 "Ignore too short 20/40 BSS Coexistence Management frame");
53@@ -410,6 +413,9 @@
54 void ht40_intolerant_add(struct hostapd_iface *iface, struct sta_info *sta)
55 {
56 if (iface->current_mode->mode != HOSTAPD_MODE_IEEE80211G)
57+ return;
58+
59+ if (iface->conf->noscan || iface->conf->no_ht_coex)
60 return;
61
62 wpa_printf(MSG_INFO, "HT: Forty MHz Intolerant is set by STA " MACSTR