[openwrt/openwrt] mac80211: add fix for receiving STP frames on mesh
LEDE Commits
lede-commits at lists.infradead.org
Mon Jul 8 12:17:17 PDT 2024
hauke pushed a commit to openwrt/openwrt.git, branch openwrt-23.05:
https://git.openwrt.org/c145f0f8f63b2e5578ecf3d9487eb864cdfedbd6
commit c145f0f8f63b2e5578ecf3d9487eb864cdfedbd6
Author: Felix Fietkau <nbd at nbd.name>
AuthorDate: Tue Jul 11 14:38:06 2023 +0200
mac80211: add fix for receiving STP frames on mesh
Fix length in ethernet header
Signed-off-by: Felix Fietkau <nbd at nbd.name>
(cherry picked from commit 8f7be2a2ba79987bd150f5f4e266daf96fd94e32)
Link: https://github.com/openwrt/openwrt/pull/15898
Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
...11-fix-receving-mesh-packets-without-RFC1.patch | 25 ++++++++++++++++++++++
...date-Transition-Disable-policy-during-por.patch | 2 +-
2 files changed, 26 insertions(+), 1 deletion(-)
diff --git a/package/kernel/mac80211/patches/subsys/339-wifi-cfg80211-fix-receving-mesh-packets-without-RFC1.patch b/package/kernel/mac80211/patches/subsys/339-wifi-cfg80211-fix-receving-mesh-packets-without-RFC1.patch
new file mode 100644
index 0000000000..e32c6ae1f3
--- /dev/null
+++ b/package/kernel/mac80211/patches/subsys/339-wifi-cfg80211-fix-receving-mesh-packets-without-RFC1.patch
@@ -0,0 +1,25 @@
+From: Felix Fietkau <nbd at nbd.name>
+Date: Tue, 11 Jul 2023 13:30:12 +0200
+Subject: [PATCH] wifi: cfg80211: fix receving mesh packets without RFC1042
+ header
+
+Fix ethernet header length field after stripping the mesh header
+
+Cc: stable at vger.kernel.org
+Link: https://lore.kernel.org/all/CT5GNZSK28AI.2K6M69OXM9RW5@syracuse/
+Fixes: 986e43b19ae9 ("wifi: mac80211: fix receiving A-MSDU frames on mesh interfaces")
+Reported-by: Nicolas Escande <nico.escande at gmail.com>
+Signed-off-by: Felix Fietkau <nbd at nbd.name>
+---
+
+--- a/net/wireless/util.c
++++ b/net/wireless/util.c
+@@ -580,6 +580,8 @@ int ieee80211_strip_8023_mesh_hdr(struct
+ hdrlen += ETH_ALEN + 2;
+ else if (!pskb_may_pull(skb, hdrlen))
+ return -EINVAL;
++ else
++ payload.eth.h_proto = htons(skb->len - hdrlen);
+
+ mesh_addr = skb->data + sizeof(payload.eth) + ETH_ALEN;
+ switch (payload.flags & MESH_FLAGS_AE) {
diff --git a/package/kernel/mac80211/patches/subsys/341-v6.2-cfg80211-Update-Transition-Disable-policy-during-por.patch b/package/kernel/mac80211/patches/subsys/341-v6.2-cfg80211-Update-Transition-Disable-policy-during-por.patch
index be332e2275..e8ce7f51a3 100644
--- a/package/kernel/mac80211/patches/subsys/341-v6.2-cfg80211-Update-Transition-Disable-policy-during-por.patch
+++ b/package/kernel/mac80211/patches/subsys/341-v6.2-cfg80211-Update-Transition-Disable-policy-during-por.patch
@@ -176,7 +176,7 @@ Signed-off-by: Johannes Berg <johannes.berg at intel.com>
* Use the wdev event list so that if there are pending
--- a/net/wireless/util.c
+++ b/net/wireless/util.c
-@@ -1057,7 +1057,9 @@ void cfg80211_process_wdev_events(struct
+@@ -1059,7 +1059,9 @@ void cfg80211_process_wdev_events(struct
__cfg80211_leave(wiphy_to_rdev(wdev->wiphy), wdev);
break;
case EVENT_PORT_AUTHORIZED:
More information about the lede-commits
mailing list