From: Felix Fietkau Date: Tue, 12 Jan 2010 03:10:03 +0000 (+0000) Subject: mac80211: upgrade to a new unofficial snapshot based on wireless-testing+wireless-2.6 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=1d109f9eb2c0c22e0b9781660b248ef3c3d13d75;p=librecmc%2Flibrecmc.git mac80211: upgrade to a new unofficial snapshot based on wireless-testing+wireless-2.6 SVN-Revision: 19110 --- diff --git a/package/mac80211/Makefile b/package/mac80211/Makefile index 652603af65..0f02b48356 100644 --- a/package/mac80211/Makefile +++ b/package/mac80211/Makefile @@ -10,12 +10,12 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=mac80211 -PKG_VERSION:=2010-01-07 -PKG_RELEASE:=8 -PKG_SOURCE_URL:= \ - http://www.orbit-lab.org/kernel/compat-wireless-2.6/2009/12 \ - http://wireless.kernel.org/download/compat-wireless-2.6 -PKG_MD5SUM:=f783d3d4a140a76855916b54fa18be47 +PKG_VERSION:=2010-01-11 +PKG_RELEASE:=1 +PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources +# http://www.orbit-lab.org/kernel/compat-wireless-2.6/2010/11 \ +# http://wireless.kernel.org/download/compat-wireless-2.6 +PKG_MD5SUM:=78a36bb7d28be7028f640a10eaa4692b PKG_SOURCE:=compat-wireless-$(PKG_VERSION).tar.bz2 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION) diff --git a/package/mac80211/patches/530-mac80211_queue_fix.patch b/package/mac80211/patches/530-mac80211_queue_fix.patch deleted file mode 100644 index d84167392f..0000000000 --- a/package/mac80211/patches/530-mac80211_queue_fix.patch +++ /dev/null @@ -1,69 +0,0 @@ ---- a/net/mac80211/iface.c -+++ b/net/mac80211/iface.c -@@ -329,7 +329,7 @@ static int ieee80211_open(struct net_dev - if (sdata->vif.type == NL80211_IFTYPE_STATION) - ieee80211_queue_work(&local->hw, &sdata->u.mgd.work); - -- netif_start_queue(dev); -+ netif_tx_start_all_queues(dev); - - return 0; - err_del_interface: -@@ -357,7 +357,7 @@ static int ieee80211_stop(struct net_dev - /* - * Stop TX on this interface first. - */ -- netif_stop_queue(dev); -+ netif_tx_stop_all_queues(dev); - - /* - * Purge work for this interface. ---- a/net/mac80211/mlme.c -+++ b/net/mac80211/mlme.c -@@ -723,7 +723,7 @@ static void ieee80211_set_associated(str - ieee80211_recalc_smps(local, sdata); - mutex_unlock(&local->iflist_mtx); - -- netif_start_queue(sdata->dev); -+ netif_tx_start_all_queues(sdata->dev); - netif_carrier_on(sdata->dev); - } - -@@ -759,7 +759,7 @@ static void ieee80211_set_disassoc(struc - * time -- we don't want the scan code to enable queues. - */ - -- netif_stop_queue(sdata->dev); -+ netif_tx_stop_all_queues(sdata->dev); - netif_carrier_off(sdata->dev); - - rcu_read_lock(); ---- a/net/mac80211/offchannel.c -+++ b/net/mac80211/offchannel.c -@@ -113,7 +113,7 @@ void ieee80211_offchannel_stop_beaconing - */ - if (sdata->vif.type != NL80211_IFTYPE_STATION && - sdata->vif.type != NL80211_IFTYPE_MONITOR) -- netif_stop_queue(sdata->dev); -+ netif_tx_stop_all_queues(sdata->dev); - } - mutex_unlock(&local->iflist_mtx); - } -@@ -131,7 +131,7 @@ void ieee80211_offchannel_stop_station(s - continue; - - if (sdata->vif.type == NL80211_IFTYPE_STATION) { -- netif_stop_queue(sdata->dev); -+ netif_tx_stop_all_queues(sdata->dev); - if (sdata->u.mgd.associated) - ieee80211_offchannel_ps_enable(sdata); - } -@@ -153,7 +153,7 @@ void ieee80211_offchannel_return(struct - if (sdata->vif.type == NL80211_IFTYPE_STATION) { - if (sdata->u.mgd.associated) - ieee80211_offchannel_ps_disable(sdata); -- netif_wake_queue(sdata->dev); -+ netif_tx_wake_all_queues(sdata->dev); - } - - /* re-enable beaconing */ diff --git a/package/mac80211/patches/530-mac80211_work_fix.patch b/package/mac80211/patches/530-mac80211_work_fix.patch new file mode 100644 index 0000000000..339a52d51d --- /dev/null +++ b/package/mac80211/patches/530-mac80211_work_fix.patch @@ -0,0 +1,30 @@ +--- a/net/mac80211/scan.c ++++ b/net/mac80211/scan.c +@@ -284,6 +284,7 @@ void ieee80211_scan_completed(struct iee + ieee80211_mlme_notify_scan_completed(local); + ieee80211_ibss_notify_scan_completed(local); + ieee80211_mesh_notify_scan_completed(local); ++ ieee80211_queue_work(&local->hw, &local->work_work); + } + EXPORT_SYMBOL(ieee80211_scan_completed); + +--- a/net/mac80211/work.c ++++ b/net/mac80211/work.c +@@ -818,6 +818,7 @@ static void ieee80211_work_work(struct w + wk->chan == local->tmp_channel && + wk->chan_type == local->tmp_channel_type) { + wk->started = true; ++ wk->timeout = jiffies; + } + + if (!wk->started && !local->tmp_channel) { +@@ -935,6 +936,9 @@ void ieee80211_add_work(struct ieee80211 + if (WARN_ON(!wk->done)) + return; + ++ if (WARN_ON(!ieee80211_sdata_running(wk->sdata))) ++ return; ++ + wk->started = false; + + local = wk->sdata->local; diff --git a/package/mac80211/patches/540-mac80211_work_fix.patch b/package/mac80211/patches/540-mac80211_work_fix.patch deleted file mode 100644 index 339a52d51d..0000000000 --- a/package/mac80211/patches/540-mac80211_work_fix.patch +++ /dev/null @@ -1,30 +0,0 @@ ---- a/net/mac80211/scan.c -+++ b/net/mac80211/scan.c -@@ -284,6 +284,7 @@ void ieee80211_scan_completed(struct iee - ieee80211_mlme_notify_scan_completed(local); - ieee80211_ibss_notify_scan_completed(local); - ieee80211_mesh_notify_scan_completed(local); -+ ieee80211_queue_work(&local->hw, &local->work_work); - } - EXPORT_SYMBOL(ieee80211_scan_completed); - ---- a/net/mac80211/work.c -+++ b/net/mac80211/work.c -@@ -818,6 +818,7 @@ static void ieee80211_work_work(struct w - wk->chan == local->tmp_channel && - wk->chan_type == local->tmp_channel_type) { - wk->started = true; -+ wk->timeout = jiffies; - } - - if (!wk->started && !local->tmp_channel) { -@@ -935,6 +936,9 @@ void ieee80211_add_work(struct ieee80211 - if (WARN_ON(!wk->done)) - return; - -+ if (WARN_ON(!ieee80211_sdata_running(wk->sdata))) -+ return; -+ - wk->started = false; - - local = wk->sdata->local; diff --git a/package/mac80211/patches/540-wds_assoc_dummyframe.patch b/package/mac80211/patches/540-wds_assoc_dummyframe.patch new file mode 100644 index 0000000000..9efb3ac6d2 --- /dev/null +++ b/package/mac80211/patches/540-wds_assoc_dummyframe.patch @@ -0,0 +1,76 @@ +--- a/net/mac80211/mlme.c ++++ b/net/mac80211/mlme.c +@@ -312,6 +312,38 @@ void ieee80211_send_nullfunc(struct ieee + ieee80211_tx_skb(sdata, skb); + } + ++static void ieee80211_send_4addr_nullfunc(struct ieee80211_local *local, ++ struct ieee80211_sub_if_data *sdata) ++{ ++ struct sk_buff *skb; ++ struct ieee80211_hdr *nullfunc; ++ __le16 fc; ++ ++ if (WARN_ON(sdata->vif.type != NL80211_IFTYPE_STATION)) ++ return; ++ ++ skb = dev_alloc_skb(local->hw.extra_tx_headroom + 30); ++ if (!skb) { ++ printk(KERN_DEBUG "%s: failed to allocate buffer for 4addr " ++ "nullfunc frame\n", sdata->name); ++ return; ++ } ++ skb_reserve(skb, local->hw.extra_tx_headroom); ++ ++ nullfunc = (struct ieee80211_hdr *) skb_put(skb, 30); ++ memset(nullfunc, 0, 30); ++ fc = cpu_to_le16(IEEE80211_FTYPE_DATA | IEEE80211_STYPE_NULLFUNC | ++ IEEE80211_FCTL_FROMDS | IEEE80211_FCTL_TODS); ++ nullfunc->frame_control = fc; ++ memcpy(nullfunc->addr1, sdata->u.mgd.bssid, ETH_ALEN); ++ memcpy(nullfunc->addr2, sdata->vif.addr, ETH_ALEN); ++ memcpy(nullfunc->addr3, sdata->u.mgd.bssid, ETH_ALEN); ++ memcpy(nullfunc->addr4, sdata->vif.addr, ETH_ALEN); ++ ++ IEEE80211_SKB_CB(skb)->flags |= IEEE80211_TX_INTFL_DONT_ENCRYPT; ++ ieee80211_tx_skb(sdata, skb); ++} ++ + /* spectrum management related things */ + static void ieee80211_chswitch_work(struct work_struct *work) + { +@@ -1120,6 +1152,13 @@ static bool ieee80211_assoc_success(stru + ieee80211_set_associated(sdata, cbss, changed); + + /* ++ * If we're using 4-addr mode, let the AP know that we're ++ * doing so, so that it can create the STA VLAN on its side ++ */ ++ if (ifmgd->use_4addr) ++ ieee80211_send_4addr_nullfunc(local, sdata); ++ ++ /* + * Start timer to probe the connection to the AP now. + * Also start the timer that will detect beacon loss. + */ +--- a/net/mac80211/rx.c ++++ b/net/mac80211/rx.c +@@ -1111,6 +1111,18 @@ ieee80211_rx_h_sta_process(struct ieee80 + if (ieee80211_is_nullfunc(hdr->frame_control) || + ieee80211_is_qos_nullfunc(hdr->frame_control)) { + I802_DEBUG_INC(rx->local->rx_handlers_drop_nullfunc); ++ ++ /* ++ * If we receive a 4-addr nullfunc frame from a STA ++ * that was not moved to a 4-addr STA vlan yet, drop ++ * the frame to the monitor interface, to make sure ++ * that hostapd sees it ++ */ ++ if (ieee80211_has_a4(hdr->frame_control) && ++ (rx->sdata->vif.type == NL80211_IFTYPE_AP || ++ (rx->sdata->vif.type == NL80211_IFTYPE_AP_VLAN && ++ !rx->sdata->u.vlan.sta))) ++ return RX_DROP_MONITOR; + /* + * Update counter and free packet here to avoid + * counting this as a dropped packed. diff --git a/package/mac80211/patches/550-mac80211_action_frame_fix.patch b/package/mac80211/patches/550-mac80211_action_frame_fix.patch deleted file mode 100644 index 9283af64a7..0000000000 --- a/package/mac80211/patches/550-mac80211_action_frame_fix.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/net/mac80211/mlme.c -+++ b/net/mac80211/mlme.c -@@ -1451,7 +1451,9 @@ static void ieee80211_sta_rx_queued_mgmt - rma = ieee80211_rx_mgmt_disassoc(sdata, mgmt, skb->len); - break; - case IEEE80211_STYPE_ACTION: -- /* XXX: differentiate, can only happen for CSA now! */ -+ if (mgmt->u.action.category != WLAN_CATEGORY_SPECTRUM_MGMT) -+ break; -+ - ieee80211_sta_process_chanswitch(sdata, - &mgmt->u.action.u.chan_switch.sw_elem, - (void *)ifmgd->associated->priv); ---- a/net/mac80211/rx.c -+++ b/net/mac80211/rx.c -@@ -1934,6 +1934,10 @@ ieee80211_rx_h_action(struct ieee80211_r - } - break; - default: -+ /* do not process rejected action frames */ -+ if (mgmt->u.action.category & 0x80) -+ return RX_DROP_MONITOR; -+ - return RX_CONTINUE; - } - diff --git a/package/mac80211/patches/550-vlan_sta_lookup.patch b/package/mac80211/patches/550-vlan_sta_lookup.patch new file mode 100644 index 0000000000..ad15ca9746 --- /dev/null +++ b/package/mac80211/patches/550-vlan_sta_lookup.patch @@ -0,0 +1,98 @@ +--- a/net/mac80211/sta_info.c ++++ b/net/mac80211/sta_info.c +@@ -119,6 +119,27 @@ struct sta_info *sta_info_get(struct iee + return sta; + } + ++/* ++ * Get sta info either from the specified interface ++ * or from one of its vlans ++ */ ++struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, ++ const u8 *addr) ++{ ++ struct ieee80211_local *local = sdata->local; ++ struct sta_info *sta; ++ ++ sta = rcu_dereference(local->sta_hash[STA_HASH(addr)]); ++ while (sta) { ++ if ((sta->sdata == sdata || ++ sta->sdata->bss == sdata->bss) && ++ memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) ++ break; ++ sta = rcu_dereference(sta->hnext); ++ } ++ return sta; ++} ++ + struct sta_info *sta_info_get_by_idx(struct ieee80211_sub_if_data *sdata, + int idx) + { +--- a/net/mac80211/sta_info.h ++++ b/net/mac80211/sta_info.h +@@ -408,6 +408,9 @@ static inline u32 get_sta_flags(struct s + struct sta_info *sta_info_get(struct ieee80211_sub_if_data *sdata, + const u8 *addr); + ++struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, ++ const u8 *addr); ++ + static inline + void for_each_sta_info_type_check(struct ieee80211_local *local, + const u8 *addr, +--- a/net/mac80211/cfg.c ++++ b/net/mac80211/cfg.c +@@ -148,7 +148,7 @@ static int ieee80211_add_key(struct wiph + rcu_read_lock(); + + if (mac_addr) { +- sta = sta_info_get(sdata, mac_addr); ++ sta = sta_info_get_bss(sdata, mac_addr); + if (!sta) { + ieee80211_key_free(key); + err = -ENOENT; +@@ -179,7 +179,7 @@ static int ieee80211_del_key(struct wiph + if (mac_addr) { + ret = -ENOENT; + +- sta = sta_info_get(sdata, mac_addr); ++ sta = sta_info_get_bss(sdata, mac_addr); + if (!sta) + goto out_unlock; + +@@ -226,7 +226,7 @@ static int ieee80211_get_key(struct wiph + rcu_read_lock(); + + if (mac_addr) { +- sta = sta_info_get(sdata, mac_addr); ++ sta = sta_info_get_bss(sdata, mac_addr); + if (!sta) + goto out; + +@@ -419,7 +419,7 @@ static int ieee80211_get_station(struct + + rcu_read_lock(); + +- sta = sta_info_get(sdata, mac); ++ sta = sta_info_get_bss(sdata, mac); + if (sta) { + ret = 0; + sta_set_sinfo(sta, sinfo); +@@ -775,7 +775,7 @@ static int ieee80211_del_station(struct + if (mac) { + rcu_read_lock(); + +- sta = sta_info_get(sdata, mac); ++ sta = sta_info_get_bss(sdata, mac); + if (!sta) { + rcu_read_unlock(); + return -ENOENT; +@@ -803,7 +803,7 @@ static int ieee80211_change_station(stru + + rcu_read_lock(); + +- sta = sta_info_get(sdata, mac); ++ sta = sta_info_get_bss(sdata, mac); + if (!sta) { + rcu_read_unlock(); + return -ENOENT; diff --git a/package/mac80211/patches/560-4addr_vlan_check.patch b/package/mac80211/patches/560-4addr_vlan_check.patch new file mode 100644 index 0000000000..7079957ee6 --- /dev/null +++ b/package/mac80211/patches/560-4addr_vlan_check.patch @@ -0,0 +1,15 @@ +--- a/net/mac80211/tx.c ++++ b/net/mac80211/tx.c +@@ -1051,8 +1051,11 @@ ieee80211_tx_prepare(struct ieee80211_su + + hdr = (struct ieee80211_hdr *) skb->data; + +- if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) ++ if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) { + tx->sta = rcu_dereference(sdata->u.vlan.sta); ++ if (!tx->sta && sdata->dev->ieee80211_ptr->use_4addr) ++ return TX_DROP; ++ } + if (!tx->sta) + tx->sta = sta_info_get(sdata, hdr->addr1); + diff --git a/package/mac80211/patches/560-wds_assoc_dummyframe.patch b/package/mac80211/patches/560-wds_assoc_dummyframe.patch deleted file mode 100644 index 9efb3ac6d2..0000000000 --- a/package/mac80211/patches/560-wds_assoc_dummyframe.patch +++ /dev/null @@ -1,76 +0,0 @@ ---- a/net/mac80211/mlme.c -+++ b/net/mac80211/mlme.c -@@ -312,6 +312,38 @@ void ieee80211_send_nullfunc(struct ieee - ieee80211_tx_skb(sdata, skb); - } - -+static void ieee80211_send_4addr_nullfunc(struct ieee80211_local *local, -+ struct ieee80211_sub_if_data *sdata) -+{ -+ struct sk_buff *skb; -+ struct ieee80211_hdr *nullfunc; -+ __le16 fc; -+ -+ if (WARN_ON(sdata->vif.type != NL80211_IFTYPE_STATION)) -+ return; -+ -+ skb = dev_alloc_skb(local->hw.extra_tx_headroom + 30); -+ if (!skb) { -+ printk(KERN_DEBUG "%s: failed to allocate buffer for 4addr " -+ "nullfunc frame\n", sdata->name); -+ return; -+ } -+ skb_reserve(skb, local->hw.extra_tx_headroom); -+ -+ nullfunc = (struct ieee80211_hdr *) skb_put(skb, 30); -+ memset(nullfunc, 0, 30); -+ fc = cpu_to_le16(IEEE80211_FTYPE_DATA | IEEE80211_STYPE_NULLFUNC | -+ IEEE80211_FCTL_FROMDS | IEEE80211_FCTL_TODS); -+ nullfunc->frame_control = fc; -+ memcpy(nullfunc->addr1, sdata->u.mgd.bssid, ETH_ALEN); -+ memcpy(nullfunc->addr2, sdata->vif.addr, ETH_ALEN); -+ memcpy(nullfunc->addr3, sdata->u.mgd.bssid, ETH_ALEN); -+ memcpy(nullfunc->addr4, sdata->vif.addr, ETH_ALEN); -+ -+ IEEE80211_SKB_CB(skb)->flags |= IEEE80211_TX_INTFL_DONT_ENCRYPT; -+ ieee80211_tx_skb(sdata, skb); -+} -+ - /* spectrum management related things */ - static void ieee80211_chswitch_work(struct work_struct *work) - { -@@ -1120,6 +1152,13 @@ static bool ieee80211_assoc_success(stru - ieee80211_set_associated(sdata, cbss, changed); - - /* -+ * If we're using 4-addr mode, let the AP know that we're -+ * doing so, so that it can create the STA VLAN on its side -+ */ -+ if (ifmgd->use_4addr) -+ ieee80211_send_4addr_nullfunc(local, sdata); -+ -+ /* - * Start timer to probe the connection to the AP now. - * Also start the timer that will detect beacon loss. - */ ---- a/net/mac80211/rx.c -+++ b/net/mac80211/rx.c -@@ -1111,6 +1111,18 @@ ieee80211_rx_h_sta_process(struct ieee80 - if (ieee80211_is_nullfunc(hdr->frame_control) || - ieee80211_is_qos_nullfunc(hdr->frame_control)) { - I802_DEBUG_INC(rx->local->rx_handlers_drop_nullfunc); -+ -+ /* -+ * If we receive a 4-addr nullfunc frame from a STA -+ * that was not moved to a 4-addr STA vlan yet, drop -+ * the frame to the monitor interface, to make sure -+ * that hostapd sees it -+ */ -+ if (ieee80211_has_a4(hdr->frame_control) && -+ (rx->sdata->vif.type == NL80211_IFTYPE_AP || -+ (rx->sdata->vif.type == NL80211_IFTYPE_AP_VLAN && -+ !rx->sdata->u.vlan.sta))) -+ return RX_DROP_MONITOR; - /* - * Update counter and free packet here to avoid - * counting this as a dropped packed. diff --git a/package/mac80211/patches/570-vlan_sta_lookup.patch b/package/mac80211/patches/570-vlan_sta_lookup.patch deleted file mode 100644 index ad15ca9746..0000000000 --- a/package/mac80211/patches/570-vlan_sta_lookup.patch +++ /dev/null @@ -1,98 +0,0 @@ ---- a/net/mac80211/sta_info.c -+++ b/net/mac80211/sta_info.c -@@ -119,6 +119,27 @@ struct sta_info *sta_info_get(struct iee - return sta; - } - -+/* -+ * Get sta info either from the specified interface -+ * or from one of its vlans -+ */ -+struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, -+ const u8 *addr) -+{ -+ struct ieee80211_local *local = sdata->local; -+ struct sta_info *sta; -+ -+ sta = rcu_dereference(local->sta_hash[STA_HASH(addr)]); -+ while (sta) { -+ if ((sta->sdata == sdata || -+ sta->sdata->bss == sdata->bss) && -+ memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) -+ break; -+ sta = rcu_dereference(sta->hnext); -+ } -+ return sta; -+} -+ - struct sta_info *sta_info_get_by_idx(struct ieee80211_sub_if_data *sdata, - int idx) - { ---- a/net/mac80211/sta_info.h -+++ b/net/mac80211/sta_info.h -@@ -408,6 +408,9 @@ static inline u32 get_sta_flags(struct s - struct sta_info *sta_info_get(struct ieee80211_sub_if_data *sdata, - const u8 *addr); - -+struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, -+ const u8 *addr); -+ - static inline - void for_each_sta_info_type_check(struct ieee80211_local *local, - const u8 *addr, ---- a/net/mac80211/cfg.c -+++ b/net/mac80211/cfg.c -@@ -148,7 +148,7 @@ static int ieee80211_add_key(struct wiph - rcu_read_lock(); - - if (mac_addr) { -- sta = sta_info_get(sdata, mac_addr); -+ sta = sta_info_get_bss(sdata, mac_addr); - if (!sta) { - ieee80211_key_free(key); - err = -ENOENT; -@@ -179,7 +179,7 @@ static int ieee80211_del_key(struct wiph - if (mac_addr) { - ret = -ENOENT; - -- sta = sta_info_get(sdata, mac_addr); -+ sta = sta_info_get_bss(sdata, mac_addr); - if (!sta) - goto out_unlock; - -@@ -226,7 +226,7 @@ static int ieee80211_get_key(struct wiph - rcu_read_lock(); - - if (mac_addr) { -- sta = sta_info_get(sdata, mac_addr); -+ sta = sta_info_get_bss(sdata, mac_addr); - if (!sta) - goto out; - -@@ -419,7 +419,7 @@ static int ieee80211_get_station(struct - - rcu_read_lock(); - -- sta = sta_info_get(sdata, mac); -+ sta = sta_info_get_bss(sdata, mac); - if (sta) { - ret = 0; - sta_set_sinfo(sta, sinfo); -@@ -775,7 +775,7 @@ static int ieee80211_del_station(struct - if (mac) { - rcu_read_lock(); - -- sta = sta_info_get(sdata, mac); -+ sta = sta_info_get_bss(sdata, mac); - if (!sta) { - rcu_read_unlock(); - return -ENOENT; -@@ -803,7 +803,7 @@ static int ieee80211_change_station(stru - - rcu_read_lock(); - -- sta = sta_info_get(sdata, mac); -+ sta = sta_info_get_bss(sdata, mac); - if (!sta) { - rcu_read_unlock(); - return -ENOENT; diff --git a/package/mac80211/patches/580-4addr_vlan_check.patch b/package/mac80211/patches/580-4addr_vlan_check.patch deleted file mode 100644 index 7079957ee6..0000000000 --- a/package/mac80211/patches/580-4addr_vlan_check.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- a/net/mac80211/tx.c -+++ b/net/mac80211/tx.c -@@ -1051,8 +1051,11 @@ ieee80211_tx_prepare(struct ieee80211_su - - hdr = (struct ieee80211_hdr *) skb->data; - -- if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) -+ if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) { - tx->sta = rcu_dereference(sdata->u.vlan.sta); -+ if (!tx->sta && sdata->dev->ieee80211_ptr->use_4addr) -+ return TX_DROP; -+ } - if (!tx->sta) - tx->sta = sta_info_get(sdata, hdr->addr1); - diff --git a/package/mac80211/patches/590-endian_fix.patch b/package/mac80211/patches/590-endian_fix.patch deleted file mode 100644 index 9381a6f431..0000000000 --- a/package/mac80211/patches/590-endian_fix.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- a/net/mac80211/iface.c -+++ b/net/mac80211/iface.c -@@ -690,10 +690,10 @@ static u16 ieee80211_monitor_select_queu - return 0; - - if (skb->len < 4 || -- skb->len < rtap->it_len + 2 /* frame control */) -+ skb->len < le16_to_cpu(rtap->it_len) + 2 /* frame control */) - return 0; /* doesn't matter, frame will be dropped */ - -- hdr = (void *)((u8 *)skb->data + rtap->it_len); -+ hdr = (void *)((u8 *)skb->data + le16_to_cpu(rtap->it_len)); - - if (!ieee80211_is_data(hdr->frame_control)) { - skb->priority = 7; diff --git a/package/mac80211/patches/600-monitor_select_queue_fix.patch b/package/mac80211/patches/600-monitor_select_queue_fix.patch deleted file mode 100644 index 9a3b1d47f9..0000000000 --- a/package/mac80211/patches/600-monitor_select_queue_fix.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/net/mac80211/iface.c -+++ b/net/mac80211/iface.c -@@ -685,6 +685,7 @@ static u16 ieee80211_monitor_select_queu - struct ieee80211_local *local = sdata->local; - struct ieee80211_hdr *hdr; - struct ieee80211_radiotap_header *rtap = (void *)skb->data; -+ u8 *p; - - if (local->hw.queues < 4) - return 0; -@@ -695,11 +696,14 @@ static u16 ieee80211_monitor_select_queu - - hdr = (void *)((u8 *)skb->data + le16_to_cpu(rtap->it_len)); - -- if (!ieee80211_is_data(hdr->frame_control)) { -+ if (!ieee80211_is_data_qos(hdr->frame_control)) { - skb->priority = 7; - return ieee802_1d_to_ac[skb->priority]; - } - -+ p = ieee80211_get_qos_ctl(hdr); -+ skb->priority = *p & IEEE80211_QOS_CTL_TAG1D_MASK; -+ - return ieee80211_downgrade_queue(local, skb); - } -