summaryrefslogtreecommitdiffstats
path: root/package/network/services/hostapd/patches/360-ctrl_iface_reload.patch
diff options
context:
space:
mode:
Diffstat (limited to 'package/network/services/hostapd/patches/360-ctrl_iface_reload.patch')
-rw-r--r--package/network/services/hostapd/patches/360-ctrl_iface_reload.patch36
1 files changed, 21 insertions, 15 deletions
diff --git a/package/network/services/hostapd/patches/360-ctrl_iface_reload.patch b/package/network/services/hostapd/patches/360-ctrl_iface_reload.patch
index f5557fd8ed..06b005ea3a 100644
--- a/package/network/services/hostapd/patches/360-ctrl_iface_reload.patch
+++ b/package/network/services/hostapd/patches/360-ctrl_iface_reload.patch
@@ -1,6 +1,6 @@
--- a/hostapd/ctrl_iface.c
+++ b/hostapd/ctrl_iface.c
-@@ -43,6 +43,7 @@
+@@ -45,6 +45,7 @@
#include "wps/wps.h"
#include "config_file.h"
#include "ctrl_iface.h"
@@ -8,7 +8,7 @@
struct wpa_ctrl_dst {
-@@ -53,6 +54,7 @@ struct wpa_ctrl_dst {
+@@ -55,6 +56,7 @@ struct wpa_ctrl_dst {
int errors;
};
@@ -16,17 +16,10 @@
static void hostapd_ctrl_iface_send(struct hostapd_data *hapd, int level,
const char *buf, size_t len);
-@@ -162,6 +164,68 @@ static int hostapd_ctrl_iface_new_sta(st
+@@ -164,6 +166,61 @@ static int hostapd_ctrl_iface_new_sta(st
return 0;
}
-+static int hostapd_ctrl_iface_set_down(struct hostapd_data *hapd)
-+{
-+ if (hapd->driver->stop_ap)
-+ hapd->driver->stop_ap(hapd->drv_priv);
-+ return 0;
-+}
-+
+static char *get_option(char *opt, char *str)
+{
+ int len = strlen(str);
@@ -85,14 +78,27 @@
#ifdef CONFIG_IEEE80211W
#ifdef NEED_AP_MLME
-@@ -1761,6 +1825,10 @@ static void hostapd_ctrl_iface_receive(i
+@@ -2086,6 +2143,8 @@ static void hostapd_ctrl_iface_receive(i
} else if (os_strncmp(buf, "VENDOR ", 7) == 0) {
reply_len = hostapd_ctrl_iface_vendor(hapd, buf + 7, reply,
reply_size);
-+ } else if (os_strcmp(buf, "DOWN") == 0) {
-+ hostapd_ctrl_iface_set_down(hapd);
+ } else if (os_strncmp(buf, "UPDATE ", 7) == 0) {
+ hostapd_ctrl_iface_update(hapd, buf + 7);
+ } else if (os_strcmp(buf, "ERP_FLUSH") == 0) {
+ ieee802_1x_erp_flush(hapd);
+ #ifdef RADIUS_SERVER
+--- a/src/ap/ctrl_iface_ap.c
++++ b/src/ap/ctrl_iface_ap.c
+@@ -541,5 +541,11 @@ int hostapd_parse_csa_settings(const cha
- } else {
- os_memcpy(reply, "UNKNOWN COMMAND\n", 16);
+ int hostapd_ctrl_iface_stop_ap(struct hostapd_data *hapd)
+ {
+- return hostapd_drv_stop_ap(hapd);
++ struct hostapd_iface *iface = hapd->iface;
++ int i;
++
++ for (i = 0; i < iface->num_bss; i++)
++ hostapd_drv_stop_ap(iface->bss[i]);
++
++ return 0;
+ }