wifi: mt76: mt792x: skip MLD header rewrite for 802.3 encap TX
Subsystems (2)
PATCH 1/1 wifi: mt76: mt792x: skip MLD header rewrite for 802.3 encap TX
From: Sean Wang <[email protected]>
mt792x_tx() rewrites addr1/addr2/addr3 by treating skb->data as an 802.11 header for MLD traffic.
That is only valid for native 802.11 frames. Direct 802.3 TX can also reach this path with IEEE80211_TX_CTL_HW_80211_ENCAP set, where skb->data is not an 802.11 header.
Skip the MLD header rewrite for HW-encap packets to avoid corrupting 802.3 frame contents.
Fixes ebb1406813c6 ("wifi: mt76: mt7925: add link handling to txwi")
Signed-off-by Sean Wang <[email protected]>
--- drivers/net/wireless/mediatek/mt76/mt792x_core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/net/wireless/mediatek/mt76/mt792x_core.c +2 -1
@@ -105,7 +105,8 @@ void mt792x_tx(struct ieee80211_hw *hw, struct ieee80211_tx_control *control, wcid = &mvif->sta.deflink.wcid; } -if (vif && control->sta &&ieee80211_vif_is_mld (vif)) { +if (vif && control->sta &&ieee80211_vif_is_mld (vif) && + !(info->flags &IEEE80211_TX_CTL_HW_80211_ENCAP )) {struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;struct ieee80211_link_sta *link_sta;struct ieee80211_bss_conf *conf;
base-commit: e8c819df02436f2c2379766946735e1f06a7c923
Signature · 1 line
2.43.0