[PATCH v2 15/15] mesh: do not use offchan mgmt tx on DFS

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


From: Peter Oh <peter.oh at bowerswilkins.com>

Drivers don't allow mesh to use offchannel on management Tx.

Signed-off-by: Peter Oh <peter.oh at bowerswilkins.com>
---
 src/drivers/driver_nl80211.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c
index 73555808b..e9cb4ae2f 100644
--- a/src/drivers/driver_nl80211.c
+++ b/src/drivers/driver_nl80211.c
@@ -7148,6 +7148,7 @@ static int wpa_driver_nl80211_send_action(struct i802_bss *bss,
 	struct wpa_driver_nl80211_data *drv = bss->drv;
 	int ret = -1;
 	u8 *buf;
+	int offchanok = 1;
 	struct ieee80211_hdr *hdr;
 
 	wpa_printf(MSG_DEBUG, "nl80211: Send Action frame (ifindex=%d, "
@@ -7173,6 +7174,8 @@ static int wpa_driver_nl80211_send_action(struct i802_bss *bss,
 		os_memset(bss->rand_addr, 0, ETH_ALEN);
 	}
 
+	if (is_mesh_interface(drv->nlmode) && ieee80211_is_dfs(freq))
+		offchanok = 0;
 	if (is_ap_interface(drv->nlmode) &&
 	    (!(drv->capa.flags & WPA_DRIVER_FLAGS_OFFCHANNEL_TX) ||
 	     (int) freq == bss->freq || drv->device_ap_sme ||
@@ -7184,7 +7187,7 @@ static int wpa_driver_nl80211_send_action(struct i802_bss *bss,
 		ret = nl80211_send_frame_cmd(bss, freq, wait_time, buf,
 					     24 + data_len,
 					     &drv->send_action_cookie,
-					     no_cck, 0, 1, NULL, 0);
+					     no_cck, 0, offchanok, NULL, 0);
 
 	os_free(buf);
 	return ret;
-- 
2.11.0 (Apple Git-81)




More information about the Hostap mailing list