mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-20 22:23:27 +00:00
34705946e2
Drop outdated and by now broken patchset originally supplied by Peter Oh in August 2018 but never merged upstream. Instead add the more promissing rework recently submitted by Markus Theil who picked up Peter's patchset, fixed and completed it and added support for HE (802.11ax) in mesh mode. This is only compile tested and needs some real-life testing. Fixes: FS#3214 Fixes:167028b750
("hostapd: Update to version 2.9 (2019-08-08)") Fixes:0a3ec87a66
("hostapd: update to latest Git hostap_2_9-1238-gdd2daf0848ed") Fixes:017320ead3
("hostapd: bring back mesh patches") Signed-off-by: Daniel Golle <daniel@makrotopia.org>
40 lines
948 B
Diff
40 lines
948 B
Diff
--- a/wpa_supplicant/ap.c
|
|
+++ b/wpa_supplicant/ap.c
|
|
@@ -1466,15 +1466,35 @@ int ap_switch_channel(struct wpa_supplic
|
|
|
|
|
|
#ifdef CONFIG_CTRL_IFACE
|
|
+
|
|
+static int __ap_ctrl_iface_chanswitch(struct hostapd_iface *iface,
|
|
+ struct csa_settings *settings)
|
|
+{
|
|
+#ifdef NEED_AP_MLME
|
|
+ if (!iface || !iface->bss[0])
|
|
+ return 0;
|
|
+
|
|
+ return hostapd_switch_channel(iface->bss[0], settings);
|
|
+#else
|
|
+ return -1;
|
|
+#endif
|
|
+}
|
|
+
|
|
+
|
|
int ap_ctrl_iface_chanswitch(struct wpa_supplicant *wpa_s, const char *pos)
|
|
{
|
|
struct csa_settings settings;
|
|
int ret = hostapd_parse_csa_settings(pos, &settings);
|
|
|
|
+ if (!(wpa_s->ap_iface && wpa_s->ap_iface->bss[0]) &&
|
|
+ !(wpa_s->ifmsh && wpa_s->ifmsh->bss[0]))
|
|
+ return -1;
|
|
+
|
|
+ ret = __ap_ctrl_iface_chanswitch(wpa_s->ap_iface, &settings);
|
|
if (ret)
|
|
return ret;
|
|
|
|
- return ap_switch_channel(wpa_s, &settings);
|
|
+ return __ap_ctrl_iface_chanswitch(wpa_s->ifmsh, &settings);
|
|
}
|
|
#endif /* CONFIG_CTRL_IFACE */
|
|
|