kernel: move mv88e6xxx fix to generic backports
[openwrt/openwrt.git] / package / network / services / hostapd / patches / 350-nl80211_del_beacon_bss.patch
1 From: Felix Fietkau <nbd@openwrt.org>
2 Date: Sat, 23 Oct 2010 23:39:54 +0000
3 Subject: [PATCH] nl80211_del_beacon_bss.patch
4
5 --- a/src/drivers/driver_nl80211.c
6 +++ b/src/drivers/driver_nl80211.c
7 @@ -3075,12 +3075,12 @@ static int wpa_driver_nl80211_del_beacon
8 return 0;
9
10 wpa_printf(MSG_DEBUG, "nl80211: Remove beacon (ifindex=%d)",
11 - drv->ifindex);
12 + bss->ifindex);
13 link->beacon_set = 0;
14 link->freq = 0;
15
16 nl80211_put_wiphy_data_ap(bss);
17 - msg = nl80211_drv_msg(drv, 0, NL80211_CMD_DEL_BEACON);
18 + msg = nl80211_bss_msg(bss, 0, NL80211_CMD_DEL_BEACON);
19 if (!msg)
20 return -ENOBUFS;
21
22 @@ -6176,8 +6176,7 @@ static void nl80211_teardown_ap(struct i
23 nl80211_mgmt_unsubscribe(bss, "AP teardown");
24
25 nl80211_put_wiphy_data_ap(bss);
26 - if (bss->flink)
27 - bss->flink->beacon_set = 0;
28 + wpa_driver_nl80211_del_beacon_all(bss);
29 }
30
31
32 @@ -8977,8 +8976,6 @@ static int wpa_driver_nl80211_if_remove(
33 } else {
34 wpa_printf(MSG_DEBUG, "nl80211: First BSS - reassign context");
35 nl80211_teardown_ap(bss);
36 - if (!bss->added_if && !drv->first_bss->next)
37 - wpa_driver_nl80211_del_beacon_all(bss);
38 nl80211_destroy_bss(bss);
39 if (!bss->added_if)
40 i802_set_iface_flags(bss, 0);