1 --- a/src/ap/ieee802_11.c
2 +++ b/src/ap/ieee802_11.c
3 @@ -1506,13 +1506,6 @@ static void handle_assoc_cb(struct hosta
5 struct ieee80211_ht_capabilities ht_cap;
8 - hostapd_logger(hapd, mgmt->da, HOSTAPD_MODULE_IEEE80211,
10 - "did not acknowledge association response");
14 if (len < IEEE80211_HDRLEN + (reassoc ? sizeof(mgmt->u.reassoc_resp) :
15 sizeof(mgmt->u.assoc_resp))) {
16 printf("handle_assoc_cb(reassoc=%d) - too short payload "
17 @@ -1520,11 +1513,6 @@ static void handle_assoc_cb(struct hosta
22 - status = le_to_host16(mgmt->u.reassoc_resp.status_code);
24 - status = le_to_host16(mgmt->u.assoc_resp.status_code);
26 sta = ap_get_sta(hapd, mgmt->da);
28 printf("handle_assoc_cb: STA " MACSTR " not found\n",
29 @@ -1532,6 +1520,19 @@ static void handle_assoc_cb(struct hosta
34 + hostapd_logger(hapd, mgmt->da, HOSTAPD_MODULE_IEEE80211,
35 + HOSTAPD_LEVEL_DEBUG,
36 + "did not acknowledge association response");
37 + sta->flags &= ~WLAN_STA_ASSOC_REQ_OK;
42 + status = le_to_host16(mgmt->u.reassoc_resp.status_code);
44 + status = le_to_host16(mgmt->u.assoc_resp.status_code);
46 if (status != WLAN_STATUS_SUCCESS)
49 @@ -1830,6 +1831,9 @@ void ieee802_11_rx_from_unknown(struct h
51 sta = ap_get_sta(hapd, src);
52 if (sta && (sta->flags & WLAN_STA_ASSOC)) {
53 + if (!hapd->conf->wds_sta)
56 if (wds && !(sta->flags & WLAN_STA_WDS)) {
57 wpa_printf(MSG_DEBUG, "Enable 4-address WDS mode for "
58 "STA " MACSTR " (aid %u)",
59 --- a/src/drivers/driver_nl80211.c
60 +++ b/src/drivers/driver_nl80211.c
61 @@ -2661,10 +2661,10 @@ static int wpa_driver_nl80211_capa(struc
62 drv->data_tx_status = info.data_tx_status;
65 - * If poll command is supported mac80211 is new enough to
66 - * have everything we need to not need monitor interfaces.
67 + * If poll command and tx status are supported, mac80211 is new enough
68 + * to have everything we need to not need monitor interfaces.
70 - drv->use_monitor = !info.poll_command_supported;
71 + drv->use_monitor = !info.poll_command_supported || !info.data_tx_status;
73 if (drv->device_ap_sme && drv->use_monitor) {
75 @@ -6392,8 +6392,8 @@ static int wpa_driver_nl80211_hapd_send_
76 pos = (u8 *) (hdr + 1);
79 - /* add an empty QoS header if needed */
81 + /* Set highest priority in QoS header */
86 @@ -7698,6 +7698,10 @@ static int i802_set_wds_sta(void *priv,
88 return i802_set_sta_vlan(priv, addr, name, 0);
91 + linux_br_del_if(drv->global->ioctl_sock, bridge_ifname,
94 i802_set_sta_vlan(priv, addr, bss->ifname, 0);
95 return wpa_driver_nl80211_if_remove(priv, WPA_IF_AP_VLAN,
97 @@ -8065,7 +8069,12 @@ static int wpa_driver_nl80211_if_remove(
101 + nl80211_remove_iface(drv, ifindex);
104 + if (type != WPA_IF_AP_BSS)
107 if (bss->added_if_into_bridge) {
108 if (linux_br_del_if(drv->global->ioctl_sock, bss->brname,
110 @@ -8079,13 +8088,6 @@ static int wpa_driver_nl80211_if_remove(
112 bss->brname, strerror(errno));
114 -#endif /* HOSTAPD */
116 - nl80211_remove_iface(drv, ifindex);
119 - if (type != WPA_IF_AP_BSS)
122 if (bss != &drv->first_bss) {
123 struct i802_bss *tbss;