[rdkb][common][bsp][Refactor and sync wifi from openwrt]
[Description]
1dacd97b [MAC80211][WiFi6][Misc][Fix patch fail]
7c02334a [MAC80211][WiFi7][Misc][Fix build fail because of mt76 version upgradation]
7a073097 [MAC80211][WiFi7][misc][ensure the first MLD bss is bss[0]]
27e2304c [MAC80211][WiFi6][mt76][Refactor due to atenl change]
1e1eb98e [MAC80211][WiFi6/7][app][Add single wiphy support for atenl & iwpriv wrapper]
d4101c33 [MAC80211][WiFi7][mt76][enable lftp for wifi7 r1 cert]
55f5732f [MAC80211][WiFi7][hostapd][set ctrl_interface for all bss]
[Release-log]
Change-Id: I9cad01561c310576a9e5bdc9f1b8eec3025e51d9
diff --git a/recipes-wifi/linux-mt76/files/patches-3.x/0066-mtk-wifi-mt76-mt7996-do-not-report-netdev-stats-on-m.patch b/recipes-wifi/linux-mt76/files/patches-3.x/0066-mtk-wifi-mt76-mt7996-do-not-report-netdev-stats-on-m.patch
new file mode 100644
index 0000000..d86ca2c
--- /dev/null
+++ b/recipes-wifi/linux-mt76/files/patches-3.x/0066-mtk-wifi-mt76-mt7996-do-not-report-netdev-stats-on-m.patch
@@ -0,0 +1,37 @@
+From 947b71bb7b65824acf8dbaa984ead4ce638f4005 Mon Sep 17 00:00:00 2001
+From: Shayne Chen <shayne.chen@mediatek.com>
+Date: Thu, 26 Oct 2023 17:27:43 +0800
+Subject: [PATCH 066/116] mtk: wifi: mt76: mt7996: do not report netdev stats
+ on monitor vif
+
+This fixes the following NULL pointer crash when enabling monitor mode:
+[ 205.593158] Call trace:
+[ 205.595597] mt7996_mcu_rx_event+0x4a0/0x6e8 [mt7996e]
+[ 205.600725] mt7996_queue_rx_skb+0x6e4/0xfa0 [mt7996e]
+[ 205.605851] mt76_dma_rx_poll+0x384/0x420 [mt76]
+[ 205.610459] __napi_poll+0x38/0x1c0
+[ 205.613935] napi_threaded_poll+0x80/0xe8
+[ 205.617934] kthread+0x124/0x128
+
+Signed-off-by: Shayne Chen <shayne.chen@mediatek.com>
+---
+ mt7996/mcu.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/mt7996/mcu.c b/mt7996/mcu.c
+index a238fdd..b886644 100644
+--- a/mt7996/mcu.c
++++ b/mt7996/mcu.c
+@@ -540,6 +540,9 @@ static inline void __mt7996_stat_to_netdev(struct mt76_phy *mphy,
+ drv_priv);
+ wdev = ieee80211_vif_to_wdev(vif);
+
++ if (vif->type == NL80211_IFTYPE_MONITOR)
++ return;
++
+ dev_sw_netstats_tx_add(wdev->netdev, tx_packets, tx_bytes);
+ dev_sw_netstats_rx_add(wdev->netdev, rx_packets, rx_bytes);
+ }
+--
+2.18.0
+