hostapd: update to git snapshot of 2018-04-09
[openwrt/staging/wigyori.git] / package / network / services / hostapd / patches / 0115-mesh-do-not-use-offchan-mgmt-tx-on-DFS.patch
1 From ab2ba9fd9ac73c83dc15a6d76d93df4434d539d6 Mon Sep 17 00:00:00 2001
2 From: Peter Oh <peter.oh@bowerswilkins.com>
3 Date: Thu, 12 Apr 2018 02:49:12 -0700
4 Subject: [PATCH 15/15] mesh: do not use offchan mgmt tx on DFS
5
6 Drivers don't allow mesh to use offchannel on management Tx.
7
8 Signed-off-by: Peter Oh <peter.oh@bowerswilkins.com>
9 ---
10 src/drivers/driver_nl80211.c | 5 ++++-
11 1 file changed, 4 insertions(+), 1 deletion(-)
12
13 --- a/src/drivers/driver_nl80211.c
14 +++ b/src/drivers/driver_nl80211.c
15 @@ -7148,6 +7148,7 @@ static int wpa_driver_nl80211_send_actio
16 struct wpa_driver_nl80211_data *drv = bss->drv;
17 int ret = -1;
18 u8 *buf;
19 + int offchanok = 1;
20 struct ieee80211_hdr *hdr;
21
22 wpa_printf(MSG_DEBUG, "nl80211: Send Action frame (ifindex=%d, "
23 @@ -7173,6 +7174,8 @@ static int wpa_driver_nl80211_send_actio
24 os_memset(bss->rand_addr, 0, ETH_ALEN);
25 }
26
27 + if (is_mesh_interface(drv->nlmode) && ieee80211_is_dfs(freq))
28 + offchanok = 0;
29 if (is_ap_interface(drv->nlmode) &&
30 (!(drv->capa.flags & WPA_DRIVER_FLAGS_OFFCHANNEL_TX) ||
31 (int) freq == bss->freq || drv->device_ap_sme ||
32 @@ -7184,7 +7187,7 @@ static int wpa_driver_nl80211_send_actio
33 ret = nl80211_send_frame_cmd(bss, freq, wait_time, buf,
34 24 + data_len,
35 &drv->send_action_cookie,
36 - no_cck, 0, 1, NULL, 0);
37 + no_cck, 0, offchanok, NULL, 0);
38
39 os_free(buf);
40 return ret;