[PATCH 08/15] mesh: set interface type to mesh before setting interface

peter.oh at bowerswilkins.com peter.oh at bowerswilkins.com
Thu Apr 12 02:35:21 PDT 2018


From: Peter Oh <poh at qca.qualcomm.com>

Correct interface type is required to start DFS CAC that can be
triggered during interface setup.

Signed-off-by: Peter Oh <poh at qca.qualcomm.com>
---
 wpa_supplicant/mesh.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/wpa_supplicant/mesh.c b/wpa_supplicant/mesh.c
index fbed375cc..4d4d5b5e7 100644
--- a/wpa_supplicant/mesh.c
+++ b/wpa_supplicant/mesh.c
@@ -336,17 +336,17 @@ static int wpa_supplicant_mesh_init(struct wpa_supplicant *wpa_s,
 
 	wpa_supplicant_conf_ap_ht(wpa_s, ssid, conf);
 
-	if (hostapd_setup_interface(ifmsh)) {
-		wpa_printf(MSG_ERROR,
-			   "Failed to initialize hostapd interface for mesh");
-		return -1;
-	}
-
 	if (wpa_drv_init_mesh(wpa_s)) {
 		wpa_msg(wpa_s, MSG_ERROR, "Failed to init mesh in driver");
 		return -1;
 	}
 
+	if (hostapd_setup_interface(ifmsh)) {
+		wpa_printf(MSG_ERROR,
+			   "Failed to initialize hostapd interface for mesh");
+		return -1;
+	}
+
 	return 0;
 out_free:
 	wpa_supplicant_mesh_deinit(wpa_s);
-- 
2.11.0 (Apple Git-81)




More information about the Hostap mailing list