aboutsummaryrefslogtreecommitdiffstats
path: root/package/kernel/mac80211/patches/subsys
diff options
context:
space:
mode:
Diffstat (limited to 'package/kernel/mac80211/patches/subsys')
-rw-r--r--package/kernel/mac80211/patches/subsys/313-mac80211-fix-encryption-key-selection-for-802.3-xmit.patch54
-rw-r--r--package/kernel/mac80211/patches/subsys/314-mac80211-fix-fast-rx-encryption-check.patch21
-rw-r--r--package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch2
-rw-r--r--package/kernel/mac80211/patches/subsys/316-mac80211-fix-a-mistake-check-for-rx_stats-update.patch28
-rw-r--r--package/kernel/mac80211/patches/subsys/336-mac80211-do-not-drop-tx-nulldata-packets-on-encrypte.patch25
-rw-r--r--package/kernel/mac80211/patches/subsys/353-mac80211-fix-station-rate-table-updates-on-assoc.patch38
-rw-r--r--package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch2
7 files changed, 2 insertions, 168 deletions
diff --git a/package/kernel/mac80211/patches/subsys/313-mac80211-fix-encryption-key-selection-for-802.3-xmit.patch b/package/kernel/mac80211/patches/subsys/313-mac80211-fix-encryption-key-selection-for-802.3-xmit.patch
deleted file mode 100644
index 9c9be2927a..0000000000
--- a/package/kernel/mac80211/patches/subsys/313-mac80211-fix-encryption-key-selection-for-802.3-xmit.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From: Felix Fietkau <nbd@nbd.name>
-Date: Wed, 16 Dec 2020 21:23:24 +0100
-Subject: [PATCH] mac80211: fix encryption key selection for 802.3 xmit
-
-When using WEP, the default unicast key needs to be selected, instead of
-the STA PTK.
-
-Signed-off-by: Felix Fietkau <nbd@nbd.name>
----
-
---- a/net/mac80211/tx.c
-+++ b/net/mac80211/tx.c
-@@ -4262,7 +4262,6 @@ netdev_tx_t ieee80211_subif_start_xmit_8
- struct ethhdr *ehdr = (struct ethhdr *)skb->data;
- struct ieee80211_key *key;
- struct sta_info *sta;
-- bool offload = true;
-
- if (unlikely(skb->len < ETH_HLEN)) {
- kfree_skb(skb);
-@@ -4278,18 +4277,22 @@ netdev_tx_t ieee80211_subif_start_xmit_8
-
- if (unlikely(IS_ERR_OR_NULL(sta) || !sta->uploaded ||
- !test_sta_flag(sta, WLAN_STA_AUTHORIZED) ||
-- sdata->control_port_protocol == ehdr->h_proto))
-- offload = false;
-- else if ((key = rcu_dereference(sta->ptk[sta->ptk_idx])) &&
-- (!(key->flags & KEY_FLAG_UPLOADED_TO_HARDWARE) ||
-- key->conf.cipher == WLAN_CIPHER_SUITE_TKIP))
-- offload = false;
--
-- if (offload)
-- ieee80211_8023_xmit(sdata, dev, sta, key, skb);
-- else
-- ieee80211_subif_start_xmit(skb, dev);
-+ sdata->control_port_protocol == ehdr->h_proto))
-+ goto skip_offload;
-
-+ key = rcu_dereference(sta->ptk[sta->ptk_idx]);
-+ if (!key)
-+ key = rcu_dereference(sdata->default_unicast_key);
-+
-+ if (key && (!(key->flags & KEY_FLAG_UPLOADED_TO_HARDWARE) ||
-+ key->conf.cipher == WLAN_CIPHER_SUITE_TKIP))
-+ goto skip_offload;
-+
-+ ieee80211_8023_xmit(sdata, dev, sta, key, skb);
-+ goto out;
-+
-+skip_offload:
-+ ieee80211_subif_start_xmit(skb, dev);
- out:
- rcu_read_unlock();
-
diff --git a/package/kernel/mac80211/patches/subsys/314-mac80211-fix-fast-rx-encryption-check.patch b/package/kernel/mac80211/patches/subsys/314-mac80211-fix-fast-rx-encryption-check.patch
deleted file mode 100644
index 679960b83c..0000000000
--- a/package/kernel/mac80211/patches/subsys/314-mac80211-fix-fast-rx-encryption-check.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From: Felix Fietkau <nbd@nbd.name>
-Date: Wed, 16 Dec 2020 21:24:19 +0100
-Subject: [PATCH] mac80211: fix fast-rx encryption check
-
-When using WEP, the default unicast key needs to be selected, instead of
-the STA PTK.
-
-Signed-off-by: Felix Fietkau <nbd@nbd.name>
----
-
---- a/net/mac80211/rx.c
-+++ b/net/mac80211/rx.c
-@@ -4195,6 +4195,8 @@ void ieee80211_check_fast_rx(struct sta_
-
- rcu_read_lock();
- key = rcu_dereference(sta->ptk[sta->ptk_idx]);
-+ if (!key)
-+ key = rcu_dereference(sdata->default_unicast_key);
- if (key) {
- switch (key->conf.cipher) {
- case WLAN_CIPHER_SUITE_TKIP:
diff --git a/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch b/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch
index 6f7c7bd74a..02486372e9 100644
--- a/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch
+++ b/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch
@@ -89,7 +89,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
/**
--- a/net/mac80211/debugfs.c
+++ b/net/mac80211/debugfs.c
-@@ -409,6 +409,7 @@ static const char *hw_flag_names[] = {
+@@ -405,6 +405,7 @@ static const char *hw_flag_names[] = {
FLAG(SUPPORTS_ONLY_HE_MULTI_BSSID),
FLAG(AMPDU_KEYBORDER_SUPPORT),
FLAG(SUPPORTS_TX_ENCAP_OFFLOAD),
diff --git a/package/kernel/mac80211/patches/subsys/316-mac80211-fix-a-mistake-check-for-rx_stats-update.patch b/package/kernel/mac80211/patches/subsys/316-mac80211-fix-a-mistake-check-for-rx_stats-update.patch
deleted file mode 100644
index 91a602bd27..0000000000
--- a/package/kernel/mac80211/patches/subsys/316-mac80211-fix-a-mistake-check-for-rx_stats-update.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From: Wen Gong <wgong@codeaurora.org>
-Date: Wed, 9 Dec 2020 11:06:29 +0800
-Subject: [PATCH] mac80211: fix a mistake check for rx_stats update
-
-It should be !is_multicast_ether_addr() in ieee80211_rx_h_sta_process()
-for the rx_stats update, below commit remove the !, this patch is to
-change it back.
-
-It lead the rx rate "iw wlan0 station dump" become invalid for some
-scenario when IEEE80211_HW_USES_RSS is set.
-
-Fixes: 09a740ce352e ("mac80211: receive and process S1G beacons")
-Signed-off-by: Wen Gong <wgong@codeaurora.org>
-Link: https://lore.kernel.org/r/1607483189-3891-1-git-send-email-wgong@codeaurora.org
-Signed-off-by: Johannes Berg <johannes.berg@intel.com>
----
-
---- a/net/mac80211/rx.c
-+++ b/net/mac80211/rx.c
-@@ -1758,7 +1758,7 @@ ieee80211_rx_h_sta_process(struct ieee80
- } else if (rx->sdata->vif.type == NL80211_IFTYPE_OCB) {
- sta->rx_stats.last_rx = jiffies;
- } else if (!ieee80211_is_s1g_beacon(hdr->frame_control) &&
-- is_multicast_ether_addr(hdr->addr1)) {
-+ !is_multicast_ether_addr(hdr->addr1)) {
- /*
- * Mesh beacons will update last_rx when if they are found to
- * match the current local configuration when processed.
diff --git a/package/kernel/mac80211/patches/subsys/336-mac80211-do-not-drop-tx-nulldata-packets-on-encrypte.patch b/package/kernel/mac80211/patches/subsys/336-mac80211-do-not-drop-tx-nulldata-packets-on-encrypte.patch
deleted file mode 100644
index d05217d1f8..0000000000
--- a/package/kernel/mac80211/patches/subsys/336-mac80211-do-not-drop-tx-nulldata-packets-on-encrypte.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From: Felix Fietkau <nbd@nbd.name>
-Date: Fri, 18 Dec 2020 20:08:06 +0100
-Subject: [PATCH] mac80211: do not drop tx nulldata packets on encrypted links
-
-ieee80211_tx_h_select_key drops any non-mgmt packets without a key when
-encryption is used. This is wrong for nulldata packets that can't be
-encrypted and are sent out for probing clients and indicating 4-address
-mode.
-
-Reported-by: Sebastian Gottschall <s.gottschall@dd-wrt.com>
-Fixes: a0761a301746 ("mac80211: drop data frames without key on encrypted links")
-Signed-off-by: Felix Fietkau <nbd@nbd.name>
----
-
---- a/net/mac80211/tx.c
-+++ b/net/mac80211/tx.c
-@@ -662,7 +662,7 @@ ieee80211_tx_h_select_key(struct ieee802
- if (!skip_hw && tx->key &&
- tx->key->flags & KEY_FLAG_UPLOADED_TO_HARDWARE)
- info->control.hw_key = &tx->key->conf;
-- } else if (!ieee80211_is_mgmt(hdr->frame_control) && tx->sta &&
-+ } else if (ieee80211_is_data_present(hdr->frame_control) && tx->sta &&
- test_sta_flag(tx->sta, WLAN_STA_USES_ENCRYPTION)) {
- return TX_DROP;
- }
diff --git a/package/kernel/mac80211/patches/subsys/353-mac80211-fix-station-rate-table-updates-on-assoc.patch b/package/kernel/mac80211/patches/subsys/353-mac80211-fix-station-rate-table-updates-on-assoc.patch
deleted file mode 100644
index 7df24fa4bd..0000000000
--- a/package/kernel/mac80211/patches/subsys/353-mac80211-fix-station-rate-table-updates-on-assoc.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From: Felix Fietkau <nbd@nbd.name>
-Date: Mon, 1 Feb 2021 00:59:14 +0100
-Subject: [PATCH] mac80211: fix station rate table updates on assoc
-
-If the driver uses .sta_add, station entries are only uploaded after the sta
-is in assoc state. Fix early station rate table updates by deferring them
-until the sta has been uploaded
-
-Signed-off-by: Felix Fietkau <nbd@nbd.name>
----
-
---- a/net/mac80211/driver-ops.c
-+++ b/net/mac80211/driver-ops.c
-@@ -125,8 +125,11 @@ int drv_sta_state(struct ieee80211_local
- } else if (old_state == IEEE80211_STA_AUTH &&
- new_state == IEEE80211_STA_ASSOC) {
- ret = drv_sta_add(local, sdata, &sta->sta);
-- if (ret == 0)
-+ if (ret == 0) {
- sta->uploaded = true;
-+ if (rcu_dereference(sta->sta.rates))
-+ drv_sta_rate_tbl_update(local, sdata, &sta->sta);
-+ }
- } else if (old_state == IEEE80211_STA_ASSOC &&
- new_state == IEEE80211_STA_AUTH) {
- drv_sta_remove(local, sdata, &sta->sta);
---- a/net/mac80211/rate.c
-+++ b/net/mac80211/rate.c
-@@ -960,7 +960,8 @@ int rate_control_set_rates(struct ieee80
- if (old)
- kfree_rcu(old, rcu_head);
-
-- drv_sta_rate_tbl_update(hw_to_local(hw), sta->sdata, pubsta);
-+ if (sta->uploaded)
-+ drv_sta_rate_tbl_update(hw_to_local(hw), sta->sdata, pubsta);
-
- ieee80211_sta_set_expected_throughput(pubsta, sta_get_expected_throughput(sta));
-
diff --git a/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch b/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch
index 48c70f8db2..7cd0417363 100644
--- a/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch
+++ b/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch
@@ -87,7 +87,7 @@
CFG80211_TESTMODE_CMD(ieee80211_testmode_cmd)
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
-@@ -1400,6 +1400,7 @@ struct ieee80211_local {
+@@ -1401,6 +1401,7 @@ struct ieee80211_local {
int dynamic_ps_forced_timeout;
int user_power_level; /* in dBm, for all interfaces */