[rdk-b][common][bsp][Refactor and sync kernel/wifi from Openwrt]

[Description]
Refactor and sync kernel/wifi from Openwrt

[Release-log]
N/A

diff --git a/recipes-wifi/hostapd/files/openwrt_script/hostapd.sh b/recipes-wifi/hostapd/files/openwrt_script/hostapd.sh
index 7eeb74e..79daa91 100644
--- a/recipes-wifi/hostapd/files/openwrt_script/hostapd.sh
+++ b/recipes-wifi/hostapd/files/openwrt_script/hostapd.sh
@@ -131,7 +131,7 @@
 
 	local base_cfg=
 
-	json_get_vars country country3 country_ie beacon_int:100 dtim_period:2 doth require_mode legacy_rates \
+	json_get_vars country country3 country_ie beacon_int:100 doth require_mode legacy_rates \
 		acs_chan_bias local_pwr_constraint spectrum_mgmt_required airtime_mode cell_density \
 		rts_threshold beacon_rate rssi_reject_assoc_rssi rssi_ignore_probe_request maxassoc
 
@@ -232,7 +232,6 @@
 	[ -n "$brlist" ] && append base_cfg "basic_rates=$brlist" "$N"
 	append base_cfg "beacon_int=$beacon_int" "$N"
 	[ -n "$rts_threshold" ] && append base_cfg "rts_threshold=$rts_threshold" "$N"
-	append base_cfg "dtim_period=$dtim_period" "$N"
 	[ "$airtime_mode" -gt 0 ] && append base_cfg "airtime_mode=$airtime_mode" "$N"
 	[ -n "$maxassoc" ] && append base_cfg "iface_max_num_sta=$maxassoc" "$N"
 
diff --git a/recipes-wifi/hostapd/files/openwrt_script/mac80211.sh b/recipes-wifi/hostapd/files/openwrt_script/mac80211.sh
index a055005..ed28052 100644
--- a/recipes-wifi/hostapd/files/openwrt_script/mac80211.sh
+++ b/recipes-wifi/hostapd/files/openwrt_script/mac80211.sh
@@ -144,6 +144,9 @@
 	json_get_values ht_capab_list ht_capab
 	json_get_values channel_list channels
 
+	[ "$auto_channel" = 0 ] && [ -z "$channel_list" ] && \
+		channel_list="$channel"
+
 	[ "$min_tx_power" -gt 0 ] && append base_cfg "min_tx_power=$min_tx_power"
 
 	set_default noscan 0
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/303-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/303-v5.16-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/303-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/303-v5.16-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/306-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/306-v5.17-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/306-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/306-v5.17-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/308-mac80211-add-support-for-.ndo_fill_forward_path.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/308-v5.17-mac80211-add-support-for-.ndo_fill_forward_path.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/308-mac80211-add-support-for-.ndo_fill_forward_path.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/308-v5.17-mac80211-add-support-for-.ndo_fill_forward_path.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/312-mac80211-split-beacon-retrieval-functions.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/312-v5.16-mac80211-split-beacon-retrieval-functions.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/312-mac80211-split-beacon-retrieval-functions.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/312-v5.16-mac80211-split-beacon-retrieval-functions.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/313-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/313-v5.16-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/313-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/313-v5.16-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/314-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/314-v5.17-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/314-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/314-v5.17-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/315-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/315-v5.17-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/315-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/315-v5.17-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/316-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/316-v5.17-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/316-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/316-v5.17-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/317-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/317-v5.17-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/317-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/317-v5.17-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/318-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/318-v5.17-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/318-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/318-v5.17-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/319-mac80211-introduce-set_radar_offchan-callback.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/319-v5.17-mac80211-introduce-set_radar_offchan-callback.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/319-mac80211-introduce-set_radar_offchan-callback.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/319-v5.17-mac80211-introduce-set_radar_offchan-callback.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/320-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/320-v5.17-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/320-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/320-v5.17-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/323-mac80211-MBSSID-support-in-interface-handling.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/323-v5.16-mac80211-MBSSID-support-in-interface-handling.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/323-mac80211-MBSSID-support-in-interface-handling.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/323-v5.16-mac80211-MBSSID-support-in-interface-handling.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/324-mac80211-MBSSID-beacon-handling-in-AP-mode.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/324-v5.18-mac80211-MBSSID-beacon-handling-in-AP-mode.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/324-mac80211-MBSSID-beacon-handling-in-AP-mode.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/324-v5.18-mac80211-MBSSID-beacon-handling-in-AP-mode.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/325-mac80211-MBSSID-channel-switch.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/325-v5.18-mac80211-MBSSID-channel-switch.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/325-mac80211-MBSSID-channel-switch.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/325-v5.18-mac80211-MBSSID-channel-switch.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/326-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/326-v5.18-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/326-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/326-v5.18-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/328-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/328-v5.19-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/328-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/328-v5.19-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/330-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/330-v6.0-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/330-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/330-v6.0-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/331-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/331-v6.0-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/331-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/331-v6.0-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/332-mac80211-consider-aql_tx_pending-when-checking-airti.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/332-v6.0-mac80211-consider-aql_tx_pending-when-checking-airti.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/332-mac80211-consider-aql_tx_pending-when-checking-airti.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/332-v6.0-mac80211-consider-aql_tx_pending-when-checking-airti.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/333-mac80211-keep-recently-active-tx-queues-in-schedulin.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/333-v6.0-mac80211-keep-recently-active-tx-queues-in-schedulin.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/333-mac80211-keep-recently-active-tx-queues-in-schedulin.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/333-v6.0-mac80211-keep-recently-active-tx-queues-in-schedulin.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/334-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/334-v6.0-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/334-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/334-v6.0-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/335-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/335-v6.0-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/335-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/335-v6.0-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/336-mac80211-only-accumulate-airtime-deficit-for-active-.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/336-v6.0-mac80211-only-accumulate-airtime-deficit-for-active-.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/336-mac80211-only-accumulate-airtime-deficit-for-active-.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/336-v6.0-mac80211-only-accumulate-airtime-deficit-for-active-.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/339-mac80211-exclude-multicast-packets-from-AQL-pending-.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/339-v6.0-mac80211-exclude-multicast-packets-from-AQL-pending-.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/339-mac80211-exclude-multicast-packets-from-AQL-pending-.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/339-v6.0-mac80211-exclude-multicast-packets-from-AQL-pending-.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/340-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/340-v5.19-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/340-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/340-v5.19-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/341-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/341-v6.0-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/341-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/341-v6.0-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/342-mac80211-Ensure-vif-queues-are-operational-after-sta.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/342-v6.0-mac80211-Ensure-vif-queues-are-operational-after-sta.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/342-mac80211-Ensure-vif-queues-are-operational-after-sta.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/342-v6.0-mac80211-Ensure-vif-queues-are-operational-after-sta.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/343-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/343-v6.1-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/343-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/343-v6.1-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/344-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/344-v6.1-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/344-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/344-v6.1-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/345-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/345-v6.1-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/345-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/345-v6.1-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/346-v6.0-wifi-mac80211-fix-mesh-airtime-link-metric-estimatin.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/346-v6.0-wifi-mac80211-fix-mesh-airtime-link-metric-estimatin.patch
new file mode 100644
index 0000000..7185a7f
--- /dev/null
+++ b/recipes-wifi/linux-mac80211/files/patches/subsys/346-v6.0-wifi-mac80211-fix-mesh-airtime-link-metric-estimatin.patch
@@ -0,0 +1,36 @@
+From: Aditya Kumar Singh <quic_adisi@quicinc.com>
+Date: Fri, 1 Jul 2022 19:06:11 +0530
+Subject: [PATCH] wifi: mac80211: fix mesh airtime link metric estimating
+
+ieee80211s_update_metric function uses sta_set_rate_info_tx
+function to get struct rate_info data from ieee80211_tx_rate
+struct, present in ieee80211_sta->deflink.tx_stats. However,
+drivers can skip tx rate calculation by setting rate idx as
+-1. Such drivers provides rate_info directly and hence
+ieee80211s metric is updated incorrectly since ieee80211_tx_rate
+has inconsistent data.
+
+Add fix to use rate_info directly if present instead of
+sta_set_rate_info_tx for updating ieee80211s metric.
+
+Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
+Link: https://lore.kernel.org/r/20220701133611.544-1-quic_adisi@quicinc.com
+Signed-off-by: Johannes Berg <johannes.berg@intel.com>
+---
+
+--- a/net/mac80211/mesh_hwmp.c
++++ b/net/mac80211/mesh_hwmp.c
+@@ -310,7 +310,12 @@ void ieee80211s_update_metric(struct iee
+ 			LINK_FAIL_THRESH)
+ 		mesh_plink_broken(sta);
+ 
+-	sta_set_rate_info_tx(sta, &sta->tx_stats.last_rate, &rinfo);
++	/* use rate info set by the driver directly if present */
++	if (st->rate)
++		rinfo = sta->tx_stats.last_rate_info;
++	else
++		sta_set_rate_info_tx(sta, &sta->tx_stats.last_rate, &rinfo);
++
+ 	ewma_mesh_tx_rate_avg_add(&sta->mesh->tx_rate_avg,
+ 				  cfg80211_calculate_bitrate(&rinfo));
+ }
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/363-bss-color-collision.patch b/recipes-wifi/linux-mac80211/files/patches/subsys/363-v5.19-bss-color-collision.patch
similarity index 100%
rename from recipes-wifi/linux-mac80211/files/patches/subsys/363-bss-color-collision.patch
rename to recipes-wifi/linux-mac80211/files/patches/subsys/363-v5.19-bss-color-collision.patch
diff --git a/recipes-wifi/linux-mac80211/files/patches/subsys/subsys.inc b/recipes-wifi/linux-mac80211/files/patches/subsys/subsys.inc
index d56faa4..8be33dc 100644
--- a/recipes-wifi/linux-mac80211/files/patches/subsys/subsys.inc
+++ b/recipes-wifi/linux-mac80211/files/patches/subsys/subsys.inc
@@ -5,43 +5,44 @@
     file://150-disable_addr_notifier.patch \
     file://210-ap_scan.patch \
     file://301-mac80211-sta-randomize-BA-session-dialog-token-alloc.patch \
-    file://303-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch \
-    file://306-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch \
+    file://303-v5.16-mac80211-set-up-the-fwd_skb-dev-for-mesh-forwarding.patch \
+    file://306-v5.17-mac80211-use-coarse-boottime-for-airtime-fairness-co.patch \
     file://307-mac80211_hwsim-make-6-GHz-channels-usable.patch \
-    file://308-mac80211-add-support-for-.ndo_fill_forward_path.patch \
+    file://308-v5.17-mac80211-add-support-for-.ndo_fill_forward_path.patch \
     file://309-mac80211-minstrel_ht-fix-MINSTREL_FRAC-macro.patch \
     file://310-mac80211-minstrel_ht-reduce-fluctuations-in-rate-pro.patch \
     file://311-mac80211-minstrel_ht-rework-rate-downgrade-code-and-.patch \
-    file://312-mac80211-split-beacon-retrieval-functions.patch \
-    file://313-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch \
-    file://314-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch \
-    file://315-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch \
-    file://316-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch \
-    file://317-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch \
-    file://318-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch \
-    file://319-mac80211-introduce-set_radar_offchan-callback.patch \
-    file://320-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch \
-    file://323-mac80211-MBSSID-support-in-interface-handling.patch \
-    file://324-mac80211-MBSSID-beacon-handling-in-AP-mode.patch \
-    file://325-mac80211-MBSSID-channel-switch.patch \
-    file://326-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch \
-    file://328-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch \
-    file://330-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch \
-    file://331-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch \
-    file://332-mac80211-consider-aql_tx_pending-when-checking-airti.patch \
-    file://333-mac80211-keep-recently-active-tx-queues-in-schedulin.patch \
-    file://334-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch \
-    file://335-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch \
-    file://336-mac80211-only-accumulate-airtime-deficit-for-active-.patch \
+    file://312-v5.16-mac80211-split-beacon-retrieval-functions.patch \
+    file://313-v5.16-nl80211-MBSSID-and-EMA-support-in-AP-mode.patch \
+    file://314-v5.17-cfg80211-implement-APIs-for-dedicated-radar-detectio.patch \
+    file://315-v5.17-cfg80211-move-offchan_cac_event-to-a-dedicated-work.patch \
+    file://316-v5.17-cfg80211-fix-possible-NULL-pointer-dereference-in-cf.patch \
+    file://317-v5.17-cfg80211-schedule-offchan_cac_abort_wk-in-cfg80211_r.patch \
+    file://318-v5.17-cfg80211-allow-continuous-radar-monitoring-on-offcha.patch \
+    file://319-v5.17-mac80211-introduce-set_radar_offchan-callback.patch \
+    file://320-v5.17-cfg80211-rename-offchannel_chain-structs-to-backgrou.patch \
+    file://323-v5.16-mac80211-MBSSID-support-in-interface-handling.patch \
+    file://324-v5.18-mac80211-MBSSID-beacon-handling-in-AP-mode.patch \
+    file://325-v5.18-mac80211-MBSSID-channel-switch.patch \
+    file://326-v5.18-mac80211-update-bssid_indicator-in-ieee80211_assign_.patch \
+    file://328-v5.19-mac80211-do-not-wake-queues-on-a-vif-that-is-being-s.patch \
+    file://330-v6.0-mac80211-switch-airtime-fairness-back-to-deficit-rou.patch \
+    file://331-v6.0-mac80211-make-sta-airtime-deficit-field-s32-instead-.patch \
+    file://332-v6.0-mac80211-consider-aql_tx_pending-when-checking-airti.patch \
+    file://333-v6.0-mac80211-keep-recently-active-tx-queues-in-schedulin.patch \
+    file://334-v6.0-mac80211-add-a-per-PHY-AQL-limit-to-improve-fairness.patch \
+    file://335-v6.0-mac80211-add-debugfs-file-to-display-per-phy-AQL-pen.patch \
+    file://336-v6.0-mac80211-only-accumulate-airtime-deficit-for-active-.patch \
     file://337-mac80211-increase-quantum-for-airtime-scheduler.patch \
-    file://339-mac80211-exclude-multicast-packets-from-AQL-pending-.patch \
-    file://340-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch \
-    file://341-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch \
-    file://342-mac80211-Ensure-vif-queues-are-operational-after-sta.patch \
-    file://343-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch \
-    file://344-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch \
-    file://345-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch \
-    file://363-bss-color-collision.patch \
+    file://339-v6.0-mac80211-exclude-multicast-packets-from-AQL-pending-.patch \
+    file://340-v5.19-wifi-mac80211-do-not-abuse-fq.lock-in-ieee80211_do_s.patch \
+    file://341-v6.0-mac80211-Fix-deadlock-Don-t-start-TX-while-holding-f.patch \
+    file://342-v6.0-mac80211-Ensure-vif-queues-are-operational-after-sta.patch \
+    file://343-v6.1-wifi-mac80211-fix-decap-offload-for-stations-on-AP_V.patch \
+    file://344-v6.1-wifi-cfg80211-fix-ieee80211_data_to_8023_exthdr-hand.patch \
+    file://345-v6.1-wifi-mac80211-do-not-drop-packets-smaller-than-the-L.patch \
+    file://346-v6.0-wifi-mac80211-fix-mesh-airtime-link-metric-estimatin.patch \
+    file://363-v5.19-bss-color-collision.patch \
     file://364-mac80211-add-support-for-restricting-netdev-features.patch \
     file://400-allow-ibss-mixed.patch \
     file://500-mac80211_configure_antenna_gain.patch \
diff --git a/recipes-wifi/linux-mt76/files/patches/0001-mt76-mt7915-rework-testmode-init-registers.patch b/recipes-wifi/linux-mt76/files/patches/0001-mt76-mt7915-rework-testmode-init-registers.patch
index b0689cd..113b411 100644
--- a/recipes-wifi/linux-mt76/files/patches/0001-mt76-mt7915-rework-testmode-init-registers.patch
+++ b/recipes-wifi/linux-mt76/files/patches/0001-mt76-mt7915-rework-testmode-init-registers.patch
@@ -1,4 +1,4 @@
-From 567a6f7be24a7f87d550f1cf3e1f1796e1770b2a Mon Sep 17 00:00:00 2001
+From 09ef6b695a93055d885869222614a936ed309dc2 Mon Sep 17 00:00:00 2001
 From: Shayne Chen <shayne.chen@mediatek.com>
 Date: Mon, 6 Jun 2022 19:46:26 +0800
 Subject: [PATCH 1/3] mt76: mt7915: rework testmode init registers
@@ -11,10 +11,10 @@
  4 files changed, 55 insertions(+), 18 deletions(-)
 
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index be1b8ea7..9c2c5086 100644
+index 3c840853..813d6f40 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
-@@ -68,6 +68,7 @@ static const u32 mt7986_reg[] = {
+@@ -113,6 +113,7 @@ static const u32 mt7986_reg[] = {
  };
  
  static const u32 mt7915_offs[] = {
@@ -22,7 +22,7 @@
  	[TMAC_CDTR]		= 0x090,
  	[TMAC_ODTR]		= 0x094,
  	[TMAC_ATCR]		= 0x098,
-@@ -142,6 +143,7 @@ static const u32 mt7915_offs[] = {
+@@ -187,6 +188,7 @@ static const u32 mt7915_offs[] = {
  };
  
  static const u32 mt7916_offs[] = {
@@ -31,10 +31,10 @@
  	[TMAC_ODTR]		= 0x0cc,
  	[TMAC_ATCR]		= 0x00c,
 diff --git a/mt7915/regs.h b/mt7915/regs.h
-index 5180dd93..2e445373 100644
+index 0c61f125..947f02f2 100644
 --- a/mt7915/regs.h
 +++ b/mt7915/regs.h
-@@ -32,6 +32,7 @@ enum reg_rev {
+@@ -47,6 +47,7 @@ enum reg_rev {
  };
  
  enum offs_rev {
@@ -42,7 +42,7 @@
  	TMAC_CDTR,
  	TMAC_ODTR,
  	TMAC_ATCR,
-@@ -182,6 +183,12 @@ enum offs_rev {
+@@ -197,6 +198,12 @@ enum offs_rev {
  #define MT_TRB_RXPSR0_RX_WTBL_PTR	GENMASK(25, 16)
  #define MT_TRB_RXPSR0_RX_RMAC_PTR	GENMASK(9, 0)
  
@@ -55,7 +55,7 @@
  /* TMAC: band 0(0x820e4000), band 1(0x820f4000) */
  #define MT_WF_TMAC_BASE(_band)		((_band) ? 0x820f4000 : 0x820e4000)
  #define MT_WF_TMAC(_band, ofs)		(MT_WF_TMAC_BASE(_band) + (ofs))
-@@ -190,6 +197,9 @@ enum offs_rev {
+@@ -205,6 +212,9 @@ enum offs_rev {
  #define MT_TMAC_TCR0_TX_BLINK		GENMASK(7, 6)
  #define MT_TMAC_TCR0_TBTT_STOP_CTRL	BIT(25)
  
@@ -65,7 +65,7 @@
  #define MT_TMAC_CDTR(_band)		MT_WF_TMAC(_band, __OFFS(TMAC_CDTR))
   #define MT_TMAC_ODTR(_band)		MT_WF_TMAC(_band, __OFFS(TMAC_ODTR))
  #define MT_TIMEOUT_VAL_PLCP		GENMASK(15, 0)
-@@ -461,8 +471,10 @@ enum offs_rev {
+@@ -484,8 +494,10 @@ enum offs_rev {
  #define MT_AGG_PCR0_VHT_PROT		BIT(13)
  #define MT_AGG_PCR0_PTA_WIN_DIS		BIT(15)
  
@@ -190,5 +190,5 @@
  	    mt76_tm_get_u8(tb[MT76_TM_ATTR_TX_DUTY_CYCLE],
  			   &td->tx_duty_cycle, 0, 99) ||
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/0002-mt76-mt7915-rework-rx-testmode-stats.patch b/recipes-wifi/linux-mt76/files/patches/0002-mt76-mt7915-rework-rx-testmode-stats.patch
index 0691685..080285a 100644
--- a/recipes-wifi/linux-mt76/files/patches/0002-mt76-mt7915-rework-rx-testmode-stats.patch
+++ b/recipes-wifi/linux-mt76/files/patches/0002-mt76-mt7915-rework-rx-testmode-stats.patch
@@ -1,4 +1,4 @@
-From 691fcd82d9e3572d2a2973361ee3c4fe9f3789f3 Mon Sep 17 00:00:00 2001
+From 2e3e45da59fc715a8d6b4771d3773536944cb480 Mon Sep 17 00:00:00 2001
 From: Shayne Chen <shayne.chen@mediatek.com>
 Date: Mon, 3 Jan 2022 17:09:53 +0800
 Subject: [PATCH 2/3] mt76: mt7915: rework rx testmode stats
@@ -15,7 +15,7 @@
  8 files changed, 109 insertions(+), 17 deletions(-)
 
 diff --git a/mac80211.c b/mac80211.c
-index e2a8ef94..7ef853cb 100644
+index 30c1bc56..e5d8f45b 100644
 --- a/mac80211.c
 +++ b/mac80211.c
 @@ -756,7 +756,8 @@ void mt76_rx(struct mt76_dev *dev, enum mt76_rxq_id q, struct sk_buff *skb)
@@ -29,7 +29,7 @@
  		if (status->flag & RX_FLAG_FAILED_FCS_CRC)
  			phy->test.rx_stats.fcs_error[q]++;
 diff --git a/mt76.h b/mt76.h
-index f9bdf16f..aef60066 100644
+index a2bccf6b..1b468ccc 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -626,6 +626,8 @@ struct mt76_testmode_ops {
@@ -59,10 +59,10 @@
  };
  
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index cf4ce3b1..31017218 100644
+index 87c65d25..b27a62aa 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1138,6 +1138,7 @@ enum {
+@@ -1143,6 +1143,7 @@ enum {
  	MCU_EXT_CMD_OFFCH_SCAN_CTRL = 0x9a,
  	MCU_EXT_CMD_SET_RDD_TH = 0x9d,
  	MCU_EXT_CMD_MURU_CTRL = 0x9f,
@@ -71,7 +71,7 @@
  	MCU_EXT_CMD_GROUP_PRE_CAL_INFO = 0xab,
  	MCU_EXT_CMD_DPD_PRE_CAL_INFO = 0xac,
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index 87cd1bff..ed949802 100644
+index c19b5d66..a788277c 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
 @@ -9,6 +9,7 @@
@@ -301,5 +301,5 @@
  	/* keep last */
  	NUM_MT76_TM_STATS_ATTRS,
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/0003-mt76-mt7915-drop-undefined-action-frame.patch b/recipes-wifi/linux-mt76/files/patches/0003-mt76-mt7915-drop-undefined-action-frame.patch
index eec1bc6..6e9b9cf 100644
--- a/recipes-wifi/linux-mt76/files/patches/0003-mt76-mt7915-drop-undefined-action-frame.patch
+++ b/recipes-wifi/linux-mt76/files/patches/0003-mt76-mt7915-drop-undefined-action-frame.patch
@@ -1,4 +1,4 @@
-From 88a457bc6d5909735c89102ef970235c2e8f4038 Mon Sep 17 00:00:00 2001
+From 6a6b3db016a9279fed1a0bf82ca22c8da4372f36 Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Thu, 14 Apr 2022 15:18:02 +0800
 Subject: [PATCH 3/3] mt76: mt7915: drop undefined action frame
@@ -8,10 +8,10 @@
  1 file changed, 6 insertions(+)
 
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 66aae55d..d1a20818 100644
+index 99123e77..3e4033e7 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -686,6 +686,8 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
+@@ -717,6 +717,8 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
  			  struct mt76_tx_info *tx_info)
  {
  	struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)tx_info->skb->data;
@@ -20,7 +20,7 @@
  	struct mt7915_dev *dev = container_of(mdev, struct mt7915_dev, mt76);
  	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(tx_info->skb);
  	struct ieee80211_key_conf *key = info->control.hw_key;
-@@ -716,6 +718,10 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
+@@ -747,6 +749,10 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
  	t = (struct mt76_txwi_cache *)(txwi + mdev->drv->txwi_size);
  	t->skb = tx_info->skb;
  
@@ -32,5 +32,5 @@
  	if (id < 0)
  		return id;
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/0004-mt76-connac-update-nss-calculation-in-txs.patch b/recipes-wifi/linux-mt76/files/patches/0004-mt76-connac-update-nss-calculation-in-txs.patch
deleted file mode 100644
index 8e61a3b..0000000
--- a/recipes-wifi/linux-mt76/files/patches/0004-mt76-connac-update-nss-calculation-in-txs.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 7280bc1aba9fa30d3a16660c8afba8656d831cb8 Mon Sep 17 00:00:00 2001
-From: Peter Chiu <chui-hao.chiu@mediatek.com>
-Date: Wed, 19 Oct 2022 16:04:10 +0800
-Subject: [PATCH] mt76: connac: update nss calculation in txs
-
-The nss is nsts divided by 2 when stbc is 1.
-
-Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com>
----
- mt76_connac_mac.c | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/mt76_connac_mac.c b/mt76_connac_mac.c
-index 8b7ec64a..fd60123f 100644
---- a/mt76_connac_mac.c
-+++ b/mt76_connac_mac.c
-@@ -567,7 +567,7 @@ bool mt76_connac2_mac_fill_txs(struct mt76_dev *dev, struct mt76_wcid *wcid,
- 	struct mt76_phy *mphy;
- 	struct rate_info rate = {};
- 	bool cck = false;
--	u32 txrate, txs, mode;
-+	u32 txrate, txs, mode, stbc;
- 
- 	txs = le32_to_cpu(txs_data[0]);
- 
-@@ -587,6 +587,10 @@ bool mt76_connac2_mac_fill_txs(struct mt76_dev *dev, struct mt76_wcid *wcid,
- 
- 	rate.mcs = FIELD_GET(MT_TX_RATE_IDX, txrate);
- 	rate.nss = FIELD_GET(MT_TX_RATE_NSS, txrate) + 1;
-+	stbc = FIELD_GET(MT_TX_RATE_STBC, txrate);
-+
-+	if (stbc && rate.nss > 1)
-+		rate.nss >>= 1;
- 
- 	if (rate.nss - 1 < ARRAY_SIZE(stats->tx_nss))
- 		stats->tx_nss[rate.nss - 1]++;
--- 
-2.18.0
-
diff --git a/recipes-wifi/linux-mt76/files/patches/0005-mt76-mt7915-fix-mt7915_mcu_set_chan_info.patch b/recipes-wifi/linux-mt76/files/patches/0005-mt76-mt7915-fix-mt7915_mcu_set_chan_info.patch
deleted file mode 100644
index 9662e57..0000000
--- a/recipes-wifi/linux-mt76/files/patches/0005-mt76-mt7915-fix-mt7915_mcu_set_chan_info.patch
+++ /dev/null
@@ -1,94 +0,0 @@
-From 508127725db04741df06adee31b2cadf53ef11f6 Mon Sep 17 00:00:00 2001
-From: Howard Hsu <howard-yh.hsu@mediatek.com>
-Date: Tue, 25 Oct 2022 14:22:52 +0800
-Subject: [PATCH] Fix parameter in channel switch mcu command. use Tx path
- instead of Tx stream in mt7915_set_chan_info().
-
-Change-Id: Ia5e7da735dbe0c5f702352ad58ea69277096e54a
----
- mt7915/main.c |  8 ++++----
- mt7915/mcu.c  | 16 ++++++++--------
- 2 files changed, 12 insertions(+), 12 deletions(-)
-
-diff --git a/mt7915/main.c b/mt7915/main.c
-index 01d64b2f..aa18e557 100644
---- a/mt7915/main.c
-+++ b/mt7915/main.c
-@@ -1016,7 +1016,7 @@ mt7915_set_antenna(struct ieee80211_hw *hw, u32 tx_ant, u32 rx_ant)
- 	struct mt7915_dev *dev = mt7915_hw_dev(hw);
- 	struct mt7915_phy *phy = mt7915_hw_phy(hw);
- 	int max_nss = hweight8(hw->wiphy->available_antennas_tx);
--	bool ext_phy = phy != &dev->phy;
-+	u8 chainshift = dev->chainshift;
- 
- 	if (!tx_ant || tx_ant != rx_ant || ffs(tx_ant) > max_nss)
- 		return -EINVAL;
-@@ -1026,10 +1026,10 @@ mt7915_set_antenna(struct ieee80211_hw *hw, u32 tx_ant, u32 rx_ant)
- 	phy->mt76->antenna_mask = tx_ant;
- 
- 	/* handle a variant of mt7916 which has 3T3R but nss2 on 5 GHz band */
--	if (is_mt7916(&dev->mt76) && ext_phy && hweight8(tx_ant) == max_nss)
--		phy->mt76->chainmask = dev->chainmask >> dev->chainshift;
-+	if (is_mt7916(&dev->mt76) && phy->band_idx && hweight8(tx_ant) == max_nss)
-+		phy->mt76->chainmask = (dev->chainmask >> chainshift) << chainshift;
- 	else
--		phy->mt76->chainmask = tx_ant << (dev->chainshift * ext_phy);
-+		phy->mt76->chainmask = tx_ant << (chainshift * phy->band_idx);
- 
- 	mt76_set_stream_caps(phy->mt76, true);
- 	mt7915_set_stream_vht_txbf_caps(phy);
-diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 38a08b9a..b8f06957 100644
---- a/mt7915/mcu.c
-+++ b/mt7915/mcu.c
-@@ -2776,8 +2776,8 @@ int mt7915_mcu_set_chan_info(struct mt7915_phy *phy, int cmd)
- 		u8 control_ch;
- 		u8 center_ch;
- 		u8 bw;
--		u8 tx_streams_num;
--		u8 rx_streams;	/* mask or num */
-+		u8 tx_path_num;
-+		u8 rx_path;	/* mask or num */
- 		u8 switch_reason;
- 		u8 band_idx;
- 		u8 center_ch2;	/* for 80+80 only */
-@@ -2793,8 +2793,8 @@ int mt7915_mcu_set_chan_info(struct mt7915_phy *phy, int cmd)
- 		.control_ch = chandef->chan->hw_value,
- 		.center_ch = ieee80211_frequency_to_channel(freq1),
- 		.bw = mt76_connac_chan_bw(chandef),
--		.tx_streams_num = hweight8(phy->mt76->antenna_mask),
--		.rx_streams = phy->mt76->antenna_mask,
-+		.tx_path_num = hweight16(phy->mt76->chainmask),
-+		.rx_path = phy->mt76->chainmask >> (dev->chainshift * phy->band_idx),
- 		.band_idx = phy->band_idx,
- 		.channel_band = ch_band[chandef->chan->band],
- 	};
-@@ -2802,13 +2802,13 @@ int mt7915_mcu_set_chan_info(struct mt7915_phy *phy, int cmd)
- #ifdef CONFIG_NL80211_TESTMODE
- 	if (phy->mt76->test.tx_antenna_mask &&
- 	    mt76_testmode_enabled(phy->mt76)) {
--		req.tx_streams_num = fls(phy->mt76->test.tx_antenna_mask);
--		req.rx_streams = phy->mt76->test.tx_antenna_mask;
-+		req.tx_path_num = fls(phy->mt76->test.tx_antenna_mask);
-+		req.rx_path = phy->mt76->test.tx_antenna_mask;
- 	}
- #endif
- 
- 	if (mt76_connac_spe_idx(phy->mt76->antenna_mask))
--		req.tx_streams_num = fls(phy->mt76->antenna_mask);
-+		req.tx_path_num = fls(phy->mt76->antenna_mask);
- 
- 	if (cmd == MCU_EXT_CMD(SET_RX_PATH) ||
- 	    dev->mt76.hw->conf.flags & IEEE80211_CONF_MONITOR)
-@@ -2822,7 +2822,7 @@ int mt7915_mcu_set_chan_info(struct mt7915_phy *phy, int cmd)
- 		req.switch_reason = CH_SWITCH_NORMAL;
- 
- 	if (cmd == MCU_EXT_CMD(CHANNEL_SWITCH))
--		req.rx_streams = hweight8(req.rx_streams);
-+		req.rx_path = hweight8(req.rx_path);
- 
- 	if (chandef->width == NL80211_CHAN_WIDTH_80P80) {
- 		int freq2 = chandef->center_freq2;
--- 
-2.18.0
-
diff --git a/recipes-wifi/linux-mt76/files/patches/100-aggregation-definitions.patch b/recipes-wifi/linux-mt76/files/patches/100-aggregation-definitions.patch
deleted file mode 100644
index a88d571..0000000
--- a/recipes-wifi/linux-mt76/files/patches/100-aggregation-definitions.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/mt7915/init.c
-+++ b/mt7915/init.c
-@@ -327,8 +327,8 @@ mt7915_init_wiphy(struct ieee80211_hw *h
- 	struct mt7915_dev *dev = phy->dev;
- 
- 	hw->queues = 4;
--	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
--	hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
-+	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
-+	hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
- 	hw->netdev_features = NETIF_F_RXCSUM;
- 
- 	hw->radiotap_timestamp.units_pos =
diff --git a/recipes-wifi/linux-mt76/files/patches/1001-mt76-mt7915-add-mtk-internal-debug-tools-for-mt76.patch b/recipes-wifi/linux-mt76/files/patches/1001-mt76-mt7915-add-mtk-internal-debug-tools-for-mt76.patch
index 184e824..4b47ac2 100644
--- a/recipes-wifi/linux-mt76/files/patches/1001-mt76-mt7915-add-mtk-internal-debug-tools-for-mt76.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1001-mt76-mt7915-add-mtk-internal-debug-tools-for-mt76.patch
@@ -1,7 +1,7 @@
-From df2abf2cef0ea55ed0a3fc805c491934ac65a5c9 Mon Sep 17 00:00:00 2001
+From 28fa372d1081e899eb59f776a3fbb27ed7105682 Mon Sep 17 00:00:00 2001
 From: Shayne Chen <shayne.chen@mediatek.com>
 Date: Wed, 22 Jun 2022 10:39:47 +0800
-Subject: [PATCH 1001/1009] mt76: mt7915: add mtk internal debug tools for mt76
+Subject: [PATCH] mt76: mt7915: add mtk internal debug tools for mt76
 
 ---
  mt76_connac_mcu.h     |    7 +
@@ -22,10 +22,10 @@
  create mode 100644 mt7915/mtk_mcu.c
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 31017218..06813f77 100644
+index b27a62aa..f7d00726 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1104,6 +1104,7 @@ enum {
+@@ -1109,6 +1109,7 @@ enum {
  	MCU_EXT_CMD_SET_TX_POWER_CTRL = 0x11,
  	MCU_EXT_CMD_FW_LOG_2_HOST = 0x13,
  	MCU_EXT_CMD_TXBF_ACTION = 0x1e,
@@ -33,7 +33,7 @@
  	MCU_EXT_CMD_EFUSE_BUFFER_MODE = 0x21,
  	MCU_EXT_CMD_THERMAL_PROT = 0x23,
  	MCU_EXT_CMD_STA_REC_UPDATE = 0x25,
-@@ -1127,6 +1128,12 @@ enum {
+@@ -1132,6 +1133,12 @@ enum {
  	MCU_EXT_CMD_TX_POWER_FEATURE_CTRL = 0x58,
  	MCU_EXT_CMD_RXDCOC_CAL = 0x59,
  	MCU_EXT_CMD_GET_MIB_INFO = 0x5a,
@@ -47,7 +47,7 @@
  	MCU_EXT_CMD_CAL_CACHE = 0x67,
  	MCU_EXT_CMD_SET_RADAR_TH = 0x7c,
 diff --git a/mt7915/Makefile b/mt7915/Makefile
-index b794ceb7..a3474e2f 100644
+index 797ae498..a42866e9 100644
 --- a/mt7915/Makefile
 +++ b/mt7915/Makefile
 @@ -3,7 +3,7 @@
@@ -59,9 +59,8 @@
  
  mt7915e-$(CONFIG_NL80211_TESTMODE) += testmode.o
  mt7915e-$(CONFIG_MT7986_WMAC) += soc.o
-\ No newline at end of file
 diff --git a/mt7915/debugfs.c b/mt7915/debugfs.c
-index b95c81db..fd0c9d18 100644
+index 766e6208..21407030 100644
 --- a/mt7915/debugfs.c
 +++ b/mt7915/debugfs.c
 @@ -8,6 +8,9 @@
@@ -74,7 +73,7 @@
  
  /** global debugfs **/
  
-@@ -448,6 +451,9 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
+@@ -504,6 +507,9 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
  	int ret;
  
  	dev->fw.debug_wm = val ? MCU_FW_LOG_TO_HOST : 0;
@@ -84,7 +83,7 @@
  
  	if (dev->fw.debug_bin)
  		val = 16;
-@@ -472,6 +478,9 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
+@@ -528,6 +534,9 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
  		if (ret)
  			goto out;
  	}
@@ -94,7 +93,7 @@
  
  	/* WM CPU info record control */
  	mt76_clear(dev, MT_CPU_UTIL_CTRL, BIT(0));
-@@ -479,6 +488,12 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
+@@ -535,6 +544,12 @@ mt7915_fw_debug_wm_set(void *data, u64 val)
  	mt76_wr(dev, MT_MCU_WM_CIRQ_IRQ_MASK_CLR_ADDR, BIT(5));
  	mt76_wr(dev, MT_MCU_WM_CIRQ_IRQ_SOFT_ADDR, BIT(5));
  
@@ -107,7 +106,7 @@
  out:
  	if (ret)
  		dev->fw.debug_wm = 0;
-@@ -491,7 +506,11 @@ mt7915_fw_debug_wm_get(void *data, u64 *val)
+@@ -547,7 +562,11 @@ mt7915_fw_debug_wm_get(void *data, u64 *val)
  {
  	struct mt7915_dev *dev = data;
  
@@ -120,7 +119,7 @@
  
  	return 0;
  }
-@@ -576,6 +595,17 @@ mt7915_fw_debug_bin_set(void *data, u64 val)
+@@ -632,6 +651,17 @@ mt7915_fw_debug_bin_set(void *data, u64 val)
  
  	relay_reset(dev->relay_fwlog);
  
@@ -138,7 +137,7 @@
  	return mt7915_fw_debug_wm_set(dev, dev->fw.debug_wm);
  }
  
-@@ -1038,6 +1068,11 @@ int mt7915_init_debugfs(struct mt7915_phy *phy)
+@@ -1090,6 +1120,11 @@ int mt7915_init_debugfs(struct mt7915_phy *phy)
  	if (!ext_phy)
  		dev->debugfs_dir = dir;
  
@@ -150,7 +149,7 @@
  	return 0;
  }
  
-@@ -1078,17 +1113,53 @@ void mt7915_debugfs_rx_fw_monitor(struct mt7915_dev *dev, const void *data, int
+@@ -1130,17 +1165,53 @@ void mt7915_debugfs_rx_fw_monitor(struct mt7915_dev *dev, const void *data, int
  		.msg_type = cpu_to_le16(PKT_TYPE_RX_FW_MONITOR),
  	};
  
@@ -205,10 +204,10 @@
  
  	if (dev->relay_fwlog)
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index d1a20818..88616e1e 100644
+index 3e4033e7..931a3a14 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -240,6 +240,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -271,6 +271,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
  	__le16 fc = 0;
  	int idx;
  
@@ -219,7 +218,7 @@
  	memset(status, 0, sizeof(*status));
  
  	if ((rxd1 & MT_RXD1_NORMAL_BAND_IDX) && !phy->band_idx) {
-@@ -423,6 +427,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -454,6 +458,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
  	}
  
  	hdr_gap = (u8 *)rxd - skb->data + 2 * remove_pad;
@@ -230,7 +229,7 @@
  	if (hdr_trans && ieee80211_has_morefrags(fc)) {
  		struct ieee80211_vif *vif;
  		int err;
-@@ -764,6 +772,12 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
+@@ -795,6 +803,12 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
  	tx_info->buf[1].skip_unmap = true;
  	tx_info->nbuf = MT_CT_DMA_BUF_NUM;
  
@@ -244,10 +243,10 @@
  }
  
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 0dffe82f..7913059c 100644
+index fe5ec166..16ae61e5 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -62,7 +62,11 @@ static int mt7915_start(struct ieee80211_hw *hw)
+@@ -58,7 +58,11 @@ int mt7915_run(struct ieee80211_hw *hw)
  	if (ret)
  		goto out;
  
@@ -260,7 +259,7 @@
  		goto out;
  
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 2f6d3287..c710624d 100644
+index 09e3dd8e..9cd06a0c 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
 @@ -195,6 +195,11 @@ mt7915_mcu_send_message(struct mt76_dev *mdev, struct sk_buff *skb,
@@ -275,7 +274,7 @@
  	return mt76_tx_queue_skb_raw(dev, mdev->q_mcu[qid], skb, 0);
  }
  
-@@ -3178,6 +3183,8 @@ int mt7915_mcu_set_sku_en(struct mt7915_phy *phy, bool enable)
+@@ -3199,6 +3204,8 @@ int mt7915_mcu_set_sku_en(struct mt7915_phy *phy, bool enable)
  		.sku_enable = enable,
  	};
  
@@ -284,7 +283,7 @@
  	return mt76_mcu_send_msg(&dev->mt76,
  				 MCU_EXT_CMD(TX_POWER_FEATURE_CTRL), &req,
  				 sizeof(req), true);
-@@ -3453,6 +3460,43 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
+@@ -3474,6 +3481,43 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
  				 &req, sizeof(req), true);
  }
  
@@ -328,7 +327,7 @@
  int mt7915_mcu_rf_regval(struct mt7915_dev *dev, u32 regidx, u32 *val, bool set)
  {
  	struct {
-@@ -3481,3 +3525,22 @@ int mt7915_mcu_rf_regval(struct mt7915_dev *dev, u32 regidx, u32 *val, bool set)
+@@ -3502,3 +3546,22 @@ int mt7915_mcu_rf_regval(struct mt7915_dev *dev, u32 regidx, u32 *val, bool set)
  
  	return 0;
  }
@@ -352,10 +351,10 @@
 +}
 +#endif
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index ed949802..bfb822fa 100644
+index a788277c..7f1216fe 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -259,6 +259,10 @@ enum {
+@@ -261,6 +261,10 @@ enum {
  	MCU_WA_PARAM_PDMA_RX = 0x04,
  	MCU_WA_PARAM_CPU_UTIL = 0x0b,
  	MCU_WA_PARAM_RED = 0x0e,
@@ -367,7 +366,7 @@
  
  enum mcu_mmps_mode {
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index fe6a6d3b..c0dfe105 100644
+index 9cb680e7..25bec88f 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
 @@ -9,6 +9,7 @@
@@ -378,7 +377,7 @@
  #define MT7915_MAX_INTERFACES		19
  #define MT7915_WTBL_SIZE		288
  #define MT7916_WTBL_SIZE		544
-@@ -336,6 +337,29 @@ struct mt7915_dev {
+@@ -366,6 +367,29 @@ struct mt7915_dev {
  	struct reset_control *rstc;
  	void __iomem *dcm;
  	void __iomem *sku;
@@ -408,7 +407,7 @@
  };
  
  enum {
-@@ -594,4 +618,24 @@ void mt7915_sta_add_debugfs(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
+@@ -638,4 +662,24 @@ void mt7915_sta_add_debugfs(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
  int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  			 bool pci, int *irq);
  
@@ -4892,5 +4891,5 @@
  	return ret;
  }
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1002-mt76-mt7915-csi-implement-csi-support.patch b/recipes-wifi/linux-mt76/files/patches/1002-mt76-mt7915-csi-implement-csi-support.patch
index e6af65a..654af4f 100644
--- a/recipes-wifi/linux-mt76/files/patches/1002-mt76-mt7915-csi-implement-csi-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1002-mt76-mt7915-csi-implement-csi-support.patch
@@ -1,7 +1,7 @@
-From a8eebb6485cf276131d9c57f2a20839740900e12 Mon Sep 17 00:00:00 2001
+From aeb6b9d251b7bf150fbfcff1cae4e7041d6ae020 Mon Sep 17 00:00:00 2001
 From: Bo Jiao <Bo.Jiao@mediatek.com>
 Date: Mon, 6 Jun 2022 20:13:02 +0800
-Subject: [PATCH 1002/1009] mt76: mt7915: csi: implement csi support
+Subject: [PATCH 1002/1008] mt76: mt7915: csi: implement csi support
 
 ---
  mt76_connac_mcu.h |   2 +
@@ -17,10 +17,10 @@
  create mode 100644 mt7915/vendor.h
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 06813f77..5d7c911c 100644
+index f7d00726..dc1a2ef7 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -979,6 +979,7 @@ enum {
+@@ -984,6 +984,7 @@ enum {
  	MCU_EXT_EVENT_CSA_NOTIFY = 0x4f,
  	MCU_EXT_EVENT_BCC_NOTIFY = 0x75,
  	MCU_EXT_EVENT_MURU_CTRL = 0x9f,
@@ -28,7 +28,7 @@
  };
  
  enum {
-@@ -1150,6 +1151,7 @@ enum {
+@@ -1155,6 +1156,7 @@ enum {
  	MCU_EXT_CMD_GROUP_PRE_CAL_INFO = 0xab,
  	MCU_EXT_CMD_DPD_PRE_CAL_INFO = 0xac,
  	MCU_EXT_CMD_PHY_STAT_INFO = 0xad,
@@ -37,7 +37,7 @@
  
  enum {
 diff --git a/mt7915/Makefile b/mt7915/Makefile
-index a3474e2f..e272c826 100644
+index c663ceb1..830589d0 100644
 --- a/mt7915/Makefile
 +++ b/mt7915/Makefile
 @@ -1,9 +1,9 @@
@@ -52,12 +52,12 @@
  
  mt7915e-$(CONFIG_NL80211_TESTMODE) += testmode.o
  mt7915e-$(CONFIG_MT7986_WMAC) += soc.o
-\ No newline at end of file
+ mt7915e-$(CONFIG_DEV_COREDUMP) += coredump.o
 diff --git a/mt7915/init.c b/mt7915/init.c
-index 416e5acb..34b5df76 100644
+index 0a5f7d85..c3c4b97e 100644
 --- a/mt7915/init.c
 +++ b/mt7915/init.c
-@@ -547,6 +547,12 @@ mt7915_register_ext_phy(struct mt7915_dev *dev, struct mt7915_phy *phy)
+@@ -571,6 +571,12 @@ mt7915_register_ext_phy(struct mt7915_dev *dev, struct mt7915_phy *phy)
  	/* init wiphy according to mphy and phy */
  	mt7915_init_wiphy(mphy->hw);
  
@@ -70,7 +70,7 @@
  	ret = mt76_register_phy(mphy, true, mt76_rates,
  				ARRAY_SIZE(mt76_rates));
  	if (ret)
-@@ -1036,6 +1042,25 @@ void mt7915_set_stream_he_caps(struct mt7915_phy *phy)
+@@ -1076,6 +1082,25 @@ void mt7915_set_stream_he_caps(struct mt7915_phy *phy)
  	}
  }
  
@@ -96,7 +96,7 @@
  static void mt7915_unregister_ext_phy(struct mt7915_dev *dev)
  {
  	struct mt7915_phy *phy = mt7915_ext_phy(dev);
-@@ -1044,6 +1069,10 @@ static void mt7915_unregister_ext_phy(struct mt7915_dev *dev)
+@@ -1084,6 +1109,10 @@ static void mt7915_unregister_ext_phy(struct mt7915_dev *dev)
  	if (!phy)
  		return;
  
@@ -107,7 +107,7 @@
  	mt7915_unregister_thermal(phy);
  	mt76_unregister_phy(mphy);
  	ieee80211_free_hw(mphy->hw);
-@@ -1056,6 +1085,10 @@ static void mt7915_stop_hardware(struct mt7915_dev *dev)
+@@ -1096,6 +1125,10 @@ static void mt7915_stop_hardware(struct mt7915_dev *dev)
  	mt7915_dma_cleanup(dev);
  	tasklet_disable(&dev->irq_tasklet);
  
@@ -118,7 +118,7 @@
  	if (is_mt7986(&dev->mt76))
  		mt7986_wmac_disable(dev);
  }
-@@ -1096,6 +1129,12 @@ int mt7915_register_device(struct mt7915_dev *dev)
+@@ -1138,6 +1171,12 @@ int mt7915_register_device(struct mt7915_dev *dev)
  	dev->mt76.test_ops = &mt7915_testmode_ops;
  #endif
  
@@ -132,7 +132,7 @@
  	if (IS_ENABLED(CONFIG_MT76_LEDS)) {
  		dev->mt76.led_cdev.brightness_set = mt7915_led_set_brightness;
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index c710624d..d9ff5a35 100644
+index 9cd06a0c..f49f9fa5 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
 @@ -32,6 +32,10 @@
@@ -158,7 +158,7 @@
  	case MCU_EXT_EVENT_BCC_NOTIFY:
  		mt7915_mcu_rx_bcc_notify(dev, skb);
  		break;
-@@ -3460,6 +3469,108 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
+@@ -3481,6 +3490,108 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
  				 &req, sizeof(req), true);
  }
  
@@ -268,10 +268,10 @@
  int mt7915_dbg_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a3, bool wait_resp)
  {
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index bfb822fa..a27129c2 100644
+index 7f1216fe..974cd13c 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -480,4 +480,80 @@ enum {
+@@ -484,4 +484,80 @@ enum {
  					 sizeof(struct bss_info_bcn_cont) + \
  					 sizeof(struct bss_info_inband_discovery))
  
@@ -353,10 +353,10 @@
 +
  #endif
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index c0dfe105..bcfcf6f5 100644
+index 25bec88f..46704b39 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -274,6 +274,20 @@ struct mt7915_phy {
+@@ -287,6 +287,20 @@ struct mt7915_phy {
  		u8 spe_idx;
  	} test;
  #endif
@@ -377,7 +377,7 @@
  };
  
  struct mt7915_dev {
-@@ -618,6 +632,12 @@ void mt7915_sta_add_debugfs(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
+@@ -662,6 +676,12 @@ void mt7915_sta_add_debugfs(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
  int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  			 bool pci, int *irq);
  
@@ -915,5 +915,5 @@
 +
 +#endif
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1003-mt76-mt7915-air-monitor-support.patch b/recipes-wifi/linux-mt76/files/patches/1003-mt76-mt7915-air-monitor-support.patch
index 1a22431..f438876 100644
--- a/recipes-wifi/linux-mt76/files/patches/1003-mt76-mt7915-air-monitor-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1003-mt76-mt7915-air-monitor-support.patch
@@ -1,7 +1,7 @@
-From 77db6e402f1e3d53d433c01a9e2339aba47db48d Mon Sep 17 00:00:00 2001
+From 626ab5ee837d42274bea8476d9c59b7c9f736084 Mon Sep 17 00:00:00 2001
 From: Bo Jiao <Bo.Jiao@mediatek.com>
 Date: Tue, 11 Jan 2022 12:03:23 +0800
-Subject: [PATCH 1003/1009] mt76: mt7915: air monitor support
+Subject: [PATCH 1003/1008] mt76: mt7915: air monitor support
 
 ---
  mt76_connac_mcu.h |   2 +
@@ -13,10 +13,10 @@
  6 files changed, 440 insertions(+)
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 5d7c911c..d87ad382 100644
+index dc1a2ef7..e4a3d9dd 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1151,6 +1151,8 @@ enum {
+@@ -1156,6 +1156,8 @@ enum {
  	MCU_EXT_CMD_GROUP_PRE_CAL_INFO = 0xab,
  	MCU_EXT_CMD_DPD_PRE_CAL_INFO = 0xac,
  	MCU_EXT_CMD_PHY_STAT_INFO = 0xad,
@@ -26,10 +26,10 @@
  };
  
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 88616e1e..42c887e2 100644
+index 931a3a14..45c71c85 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -488,6 +488,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -519,6 +519,10 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
  			seq_ctrl = le16_to_cpu(hdr->seq_ctrl);
  			qos_ctl = *ieee80211_get_qos_ctl(hdr);
  		}
@@ -41,10 +41,10 @@
  		status->flag |= RX_FLAG_8023;
  	}
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 7913059c..35cd7ad5 100644
+index 16ae61e5..8068cab2 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -675,6 +675,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -688,6 +688,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  	if (ret)
  		return ret;
  
@@ -55,10 +55,10 @@
  }
  
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index bcfcf6f5..4c3bb62f 100644
+index 46704b39..f13263c7 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -229,6 +229,35 @@ struct mt7915_hif {
+@@ -242,6 +242,35 @@ struct mt7915_hif {
  	int irq;
  };
  
@@ -94,7 +94,7 @@
  struct mt7915_phy {
  	struct mt76_phy *mt76;
  	struct mt7915_dev *dev;
-@@ -287,6 +316,8 @@ struct mt7915_phy {
+@@ -300,6 +329,8 @@ struct mt7915_phy {
  		u32 interval;
  		u32 last_record;
  	} csi;
@@ -103,7 +103,7 @@
  #endif
  };
  
-@@ -636,6 +667,9 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -680,6 +711,9 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  void mt7915_vendor_register(struct mt7915_phy *phy);
  int mt7915_mcu_set_csi(struct mt7915_phy *phy, u8 mode,
  			u8 cfg, u8 v1, u32 v2, u8 *mac_addr);
@@ -545,5 +545,5 @@
 +
  #endif
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1004-mt76-mt7915-add-support-for-muru_onoff-via-debugfs.patch b/recipes-wifi/linux-mt76/files/patches/1004-mt76-mt7915-add-support-for-muru_onoff-via-debugfs.patch
index 83a9101..c3a3e7a 100644
--- a/recipes-wifi/linux-mt76/files/patches/1004-mt76-mt7915-add-support-for-muru_onoff-via-debugfs.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1004-mt76-mt7915-add-support-for-muru_onoff-via-debugfs.patch
@@ -1,7 +1,7 @@
-From 8e92016b1c11dd9d7608f675726d5cb337f8623c Mon Sep 17 00:00:00 2001
+From e607646c35843a60f23bf5c05e385899feaf24ff Mon Sep 17 00:00:00 2001
 From: MeiChia Chiu <meichia.chiu@mediatek.com>
 Date: Wed, 22 Jun 2022 10:45:53 +0800
-Subject: [PATCH 1004/1009] mt76: mt7915: add support for muru_onoff via
+Subject: [PATCH 1004/1008] mt76: mt7915: add support for muru_onoff via
  debugfs
 
 ---
@@ -12,10 +12,10 @@
  4 files changed, 47 insertions(+), 2 deletions(-)
 
 diff --git a/mt7915/init.c b/mt7915/init.c
-index 34b5df76..479b984f 100644
+index c3c4b97e..442e19e8 100644
 --- a/mt7915/init.c
 +++ b/mt7915/init.c
-@@ -582,6 +582,7 @@ static void mt7915_init_work(struct work_struct *work)
+@@ -606,6 +606,7 @@ static void mt7915_init_work(struct work_struct *work)
  	mt7915_init_txpower(dev, &dev->mphy.sband_5g.sband);
  	mt7915_init_txpower(dev, &dev->mphy.sband_6g.sband);
  	mt7915_txbf_init(dev);
@@ -24,7 +24,7 @@
  
  void mt7915_wfsys_reset(struct mt7915_dev *dev)
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index d9ff5a35..4c047606 100644
+index f49f9fa5..59fadcd4 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
 @@ -856,13 +856,18 @@ mt7915_mcu_sta_muru_tlv(struct mt7915_dev *dev, struct sk_buff *skb,
@@ -49,10 +49,10 @@
  		muru->mimo_dl.vht_mu_bfee =
  			!!(sta->vht_cap.cap & IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE);
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index a27129c2..d3cc8283 100644
+index 974cd13c..c514cd6a 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -556,4 +556,10 @@ struct csi_data {
+@@ -560,4 +560,10 @@ struct csi_data {
  };
  #endif
  
@@ -115,5 +115,5 @@
  			    &fops_fw_debug_module);
  	debugfs_create_file("fw_debug_level", 0600, dir, dev,
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1005-mt76-certification-patches.patch b/recipes-wifi/linux-mt76/files/patches/1005-mt76-certification-patches.patch
index 00d5fb1..218edee 100644
--- a/recipes-wifi/linux-mt76/files/patches/1005-mt76-certification-patches.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1005-mt76-certification-patches.patch
@@ -1,7 +1,7 @@
-From e5d58f825b9f53695880296959dea2cc8beb7176 Mon Sep 17 00:00:00 2001
+From 1599fade954b3c82e9757a9046323f545b49a6f4 Mon Sep 17 00:00:00 2001
 From: MeiChia Chiu <meichia.chiu@mediatek.com>
 Date: Mon, 6 Jun 2022 20:15:51 +0800
-Subject: [PATCH 1005/1009] mt76: certification patches
+Subject: [PATCH 1005/1008] mt76: certification patches
 
 ---
  mt76_connac_mcu.h    |   1 +
@@ -16,10 +16,10 @@
  9 files changed, 956 insertions(+), 5 deletions(-)
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index d87ad382..01035b28 100644
+index e4a3d9dd..c4262f39 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1153,6 +1153,7 @@ enum {
+@@ -1158,6 +1158,7 @@ enum {
  	MCU_EXT_CMD_PHY_STAT_INFO = 0xad,
  	/* for vendor csi and air monitor */
  	MCU_EXT_CMD_SMESH_CTRL = 0xae,
@@ -28,18 +28,18 @@
  };
  
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 42c887e2..5609108b 100644
+index 45c71c85..d0aa305a 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -7,6 +7,7 @@
+@@ -8,6 +8,7 @@
  #include "../dma.h"
  #include "mac.h"
  #include "mcu.h"
 +#include "vendor.h"
  
- #define to_rssi(field, rxv)	((FIELD_GET(field, rxv) - 220) / 2)
+ #define to_rssi(field, rcpi)	((FIELD_GET(field, rcpi) - 220) / 2)
  
-@@ -1754,6 +1755,21 @@ static void mt7915_mac_severe_check(struct mt7915_phy *phy)
+@@ -1996,6 +1997,21 @@ static void mt7915_mac_severe_check(struct mt7915_phy *phy)
  	phy->trb_ts = trb;
  }
  
@@ -61,7 +61,7 @@
  void mt7915_mac_sta_rc_work(struct work_struct *work)
  {
  	struct mt7915_dev *dev = container_of(work, struct mt7915_dev, rc_work);
-@@ -1776,6 +1792,13 @@ void mt7915_mac_sta_rc_work(struct work_struct *work)
+@@ -2018,6 +2034,13 @@ void mt7915_mac_sta_rc_work(struct work_struct *work)
  		sta = container_of((void *)msta, struct ieee80211_sta, drv_priv);
  		vif = container_of((void *)msta->vif, struct ieee80211_vif, drv_priv);
  
@@ -76,10 +76,10 @@
  			       IEEE80211_RC_NSS_CHANGED |
  			       IEEE80211_RC_BW_CHANGED))
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 35cd7ad5..abfdc729 100644
+index 8068cab2..97bf5117 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -653,6 +653,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -664,6 +664,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  	struct mt7915_sta *msta = (struct mt7915_sta *)sta->drv_priv;
  	struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv;
  	bool ext_phy = mvif->phy != &dev->phy;
@@ -89,7 +89,7 @@
  	int ret, idx;
  
  	idx = mt76_wcid_alloc(dev->mt76.wcid_mask, MT7915_WTBL_STA);
-@@ -678,7 +681,17 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -691,7 +694,17 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  #ifdef CONFIG_MTK_VENDOR
  	mt7915_vendor_amnt_sta_remove(mvif->phy, sta);
  #endif
@@ -109,10 +109,10 @@
  
  void mt7915_mac_sta_remove(struct mt76_dev *mdev, struct ieee80211_vif *vif,
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 4c047606..8731f7d0 100644
+index 59fadcd4..1bd46cc4 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -3574,6 +3574,472 @@ mt7915_mcu_report_csi(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -3595,6 +3595,472 @@ mt7915_mcu_report_csi(struct mt7915_dev *dev, struct sk_buff *skb)
  
  	return 0;
  }
@@ -586,10 +586,10 @@
  
  #ifdef MTK_DEBUG
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index d3cc8283..aab1a6a3 100644
+index c514cd6a..c45486fd 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -396,10 +396,14 @@ enum {
+@@ -398,10 +398,14 @@ enum {
  	RATE_PARAM_FIXED = 3,
  	RATE_PARAM_MMPS_UPDATE = 5,
  	RATE_PARAM_FIXED_HE_LTF = 7,
@@ -605,7 +605,7 @@
  };
  
  #define RATE_CFG_MCS			GENMASK(3, 0)
-@@ -411,6 +415,9 @@ enum {
+@@ -413,6 +417,9 @@ enum {
  #define RATE_CFG_PHY_TYPE		GENMASK(27, 24)
  #define RATE_CFG_HE_LTF			GENMASK(31, 28)
  
@@ -615,7 +615,7 @@
  enum {
  	THERMAL_PROTECT_PARAMETER_CTRL,
  	THERMAL_PROTECT_BASIC_INFO,
-@@ -561,5 +568,203 @@ struct csi_data {
+@@ -565,5 +572,203 @@ struct csi_data {
  #define OFDMA_UL                       BIT(1)
  #define MUMIMO_DL                      BIT(2)
  #define MUMIMO_UL                      BIT(3)
@@ -820,10 +820,10 @@
  
  #endif
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 4c3bb62f..93afa3d2 100644
+index f13263c7..6458e356 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -664,6 +664,19 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -708,6 +708,19 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  			 bool pci, int *irq);
  
  #ifdef CONFIG_MTK_VENDOR
@@ -1134,5 +1134,5 @@
  
  enum mtk_vendor_attr_csi_ctrl {
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-L0.5-system-error-recovery-support.patch b/recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-L0.5-system-error-recovery-support.patch
deleted file mode 100644
index 8ff2c60..0000000
--- a/recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-L0.5-system-error-recovery-support.patch
+++ /dev/null
@@ -1,930 +0,0 @@
-From 3826960263176ad488830dd85649053ca41193f2 Mon Sep 17 00:00:00 2001
-From: Bo Jiao <Bo.Jiao@mediatek.com>
-Date: Wed, 22 Jun 2022 10:51:59 +0800
-Subject: [PATCH 1006/1009] mt76: mt7915: add L0.5 system error recovery
- support
-
----
- mt7915/debugfs.c |  88 ++++++++++++---
- mt7915/dma.c     |  48 ++++++++
- mt7915/init.c    |   8 +-
- mt7915/mac.c     | 281 +++++++++++++++++++++++++++++++++++++----------
- mt7915/main.c    |  19 +++-
- mt7915/mcu.c     |  95 ++++++++++++++--
- mt7915/mcu.h     |   3 +-
- mt7915/mmio.c    |   8 +-
- mt7915/mt7915.h  |  23 ++++
- mt7915/regs.h    |  16 +++
- 10 files changed, 491 insertions(+), 98 deletions(-)
-
-diff --git a/mt7915/debugfs.c b/mt7915/debugfs.c
-index fd0c9d18..f585eb93 100644
---- a/mt7915/debugfs.c
-+++ b/mt7915/debugfs.c
-@@ -52,12 +52,17 @@ static ssize_t
- mt7915_fw_ser_set(struct file *file, const char __user *user_buf,
- 		  size_t count, loff_t *ppos)
- {
-+#define SER_LEVEL	GENMASK(3, 0)
-+#define SER_ACTION	GENMASK(11, 8)
-+
- 	struct mt7915_phy *phy = file->private_data;
- 	struct mt7915_dev *dev = phy->dev;
--	bool ext_phy = phy != &dev->phy;
-+	u8 ser_action, ser_set, set_val;
-+	u8 band_idx = phy->band_idx;
- 	char buf[16];
- 	int ret = 0;
- 	u16 val;
-+	u32 intr;
- 
- 	if (count >= sizeof(buf))
- 		return -EINVAL;
-@@ -73,28 +78,71 @@ mt7915_fw_ser_set(struct file *file, const char __user *user_buf,
- 	if (kstrtou16(buf, 0, &val))
- 		return -EINVAL;
- 
--	switch (val) {
-+	ser_action = FIELD_GET(SER_ACTION, val);
-+	ser_set = set_val = FIELD_GET(SER_LEVEL, val);
-+
-+	switch (ser_action) {
- 	case SER_QUERY:
- 		/* grab firmware SER stats */
--		ret = mt7915_mcu_set_ser(dev, 0, 0, ext_phy);
-+		ser_set = 0;
- 		break;
--	case SER_SET_RECOVER_L1:
--	case SER_SET_RECOVER_L2:
--	case SER_SET_RECOVER_L3_RX_ABORT:
--	case SER_SET_RECOVER_L3_TX_ABORT:
--	case SER_SET_RECOVER_L3_TX_DISABLE:
--	case SER_SET_RECOVER_L3_BF:
--		ret = mt7915_mcu_set_ser(dev, SER_ENABLE, BIT(val), ext_phy);
--		if (ret)
--			return ret;
--
--		ret = mt7915_mcu_set_ser(dev, SER_RECOVER, val, ext_phy);
-+	case SER_SET:
-+		/*
-+		 * 0x100: disable system error recovery function.
-+		 * 0x101: enable system error recovery function.
-+		 * 0x103: enable l0.5 recover function.
-+		 */
-+		ser_set = !!set_val;
-+
-+		dev->ser.reset_enable = ser_set;
-+		intr = mt76_rr(dev, MT_WFDMA0_MCU_HOST_INT_ENA);
-+		if (dev->ser.reset_enable)
-+			intr |= MT_MCU_CMD_WDT_MASK;
-+		else
-+			intr &= ~MT_MCU_CMD_WDT_MASK;
-+		mt76_set(dev, MT_WFDMA0_MCU_HOST_INT_ENA, intr);
- 		break;
--	default:
-+	case SER_ENABLE:
-+		/*
-+		 * 0x200: enable system error tracking.
-+		 * 0x201: enable system error L1 recover.
-+		 * 0x202: enable system error L2 recover.
-+		 * 0x203: enable system error L3 rx abort.
-+		 * 0x204: enable system error L3 tx abort.
-+		 * 0x205: enable system error L3 tx disable.
-+		 * 0x206: enable system error L3 bf recover.
-+		 * 0x207: enable system error all recover.
-+		 */
-+		ser_set = set_val > 7 ? 0x7f : BIT(set_val);
-+		break;
-+	case SER_RECOVER:
-+		/*
-+		 * 0x300: trigger L0.5 recover.
-+		 * 0x301: trigger L1 recover.
-+		 * 0x302: trigger L2 recover.
-+		 * 0x303: trigger L3 rx abort.
-+		 * 0x304: trigger L3 tx abort
-+		 * 0x305: trigger L3 tx disable.
-+		 * 0x306: trigger L3 bf recover.
-+		 */
-+		if (!ser_set) {
-+			if (dev->ser.reset_enable) {
-+				dev->reset_state |= MT_MCU_CMD_WDT_MASK;
-+				mt7915_reset(dev);
-+			} else {
-+				dev_info(dev->mt76.dev, "SER: chip full recovery not enable\n");
-+			}
-+			goto out;
-+		}
- 		break;
-+	default:
-+		goto out;
- 	}
--
--	return ret ? ret : count;
-+	ret = mt7915_mcu_set_ser(dev, ser_action, ser_set, band_idx);
-+	if (ret)
-+		return ret;
-+out:
-+	return count;
- }
- 
- static ssize_t
-@@ -143,6 +191,12 @@ mt7915_fw_ser_get(struct file *file, char __user *user_buf,
- 			  "::E  R , SER_LMAC_WISR7_B1 = 0x%08x\n",
- 			  mt76_rr(dev, MT_SWDEF_LAMC_WISR7_BN1_STATS));
- 
-+	desc += scnprintf(buff + desc, bufsz - desc,
-+			  "\nWF RESET STATUS: EN %d, WM %d, WA %d\n",
-+			  dev->ser.reset_enable,
-+			  dev->ser.wf_reset_wm_count,
-+			  dev->ser.wf_reset_wa_count);
-+
- 	ret = simple_read_from_buffer(user_buf, count, ppos, buff, desc);
- 	kfree(buff);
- 	return ret;
-diff --git a/mt7915/dma.c b/mt7915/dma.c
-index edae8453..e3918860 100644
---- a/mt7915/dma.c
-+++ b/mt7915/dma.c
-@@ -514,6 +514,54 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
- 	return 0;
- }
- 
-+int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
-+{
-+	struct mt76_phy *mphy_ext = dev->mt76.phys[MT_BAND1];
-+	int i;
-+
-+	/* clean up hw queues */
-+	for (i = 0; i < ARRAY_SIZE(dev->mt76.phy.q_tx); i++) {
-+		mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[i], true);
-+		if (mphy_ext)
-+			mt76_queue_tx_cleanup(dev, mphy_ext->q_tx[i], true);
-+	}
-+
-+	for (i = 0; i < ARRAY_SIZE(dev->mt76.q_mcu); i++)
-+		mt76_queue_tx_cleanup(dev, dev->mt76.q_mcu[i], true);
-+
-+	mt76_for_each_q_rx(&dev->mt76, i)
-+		mt76_queue_rx_cleanup(dev, &dev->mt76.q_rx[i]);
-+
-+	/* reset wfsys */
-+	if (force)
-+		mt7915_wfsys_reset(dev);
-+
-+	/* disable wfdma */
-+	mt7915_dma_disable(dev, force);
-+
-+	/* reset hw queues */
-+	for (i = 0; i < __MT_TXQ_MAX; i++) {
-+		mt76_queue_reset(dev, dev->mphy.q_tx[i]);
-+		if (mphy_ext)
-+			mt76_queue_reset(dev, mphy_ext->q_tx[i]);
-+	}
-+
-+	for (i = 0; i < __MT_MCUQ_MAX; i++)
-+		mt76_queue_reset(dev, dev->mt76.q_mcu[i]);
-+
-+	mt76_for_each_q_rx(&dev->mt76, i)
-+		mt76_queue_reset(dev, &dev->mt76.q_rx[i]);
-+
-+	mt76_tx_status_check(&dev->mt76, true);
-+
-+	mt7915_dma_enable(dev);
-+
-+	mt76_for_each_q_rx(&dev->mt76, i)
-+		mt76_queue_rx_reset(dev, i);
-+
-+	return 0;
-+}
-+
- void mt7915_dma_cleanup(struct mt7915_dev *dev)
- {
- 	mt7915_dma_disable(dev, true);
-diff --git a/mt7915/init.c b/mt7915/init.c
-index 479b984f..d83ba2bc 100644
---- a/mt7915/init.c
-+++ b/mt7915/init.c
-@@ -262,7 +262,7 @@ static void mt7915_led_set_brightness(struct led_classdev *led_cdev,
- 		mt7915_led_set_config(led_cdev, 0xff, 0);
- }
- 
--static void
-+void
- mt7915_init_txpower(struct mt7915_dev *dev,
- 		    struct ieee80211_supported_band *sband)
- {
-@@ -449,7 +449,7 @@ mt7915_mac_init_band(struct mt7915_dev *dev, u8 band)
- 	mt76_clear(dev, MT_DMA_DCR0(band), MT_DMA_DCR0_RXD_G5_EN);
- }
- 
--static void mt7915_mac_init(struct mt7915_dev *dev)
-+void mt7915_mac_init(struct mt7915_dev *dev)
- {
- 	int i;
- 	u32 rx_len = is_mt7915(&dev->mt76) ? 0x400 : 0x680;
-@@ -479,7 +479,7 @@ static void mt7915_mac_init(struct mt7915_dev *dev)
- 	}
- }
- 
--static int mt7915_txbf_init(struct mt7915_dev *dev)
-+int mt7915_txbf_init(struct mt7915_dev *dev)
- {
- 	int ret;
- 
-@@ -1161,6 +1161,8 @@ int mt7915_register_device(struct mt7915_dev *dev)
- 
- 	mt7915_init_debugfs(&dev->phy);
- 
-+	dev->ser.hw_init_done = true;
-+
- 	return 0;
- 
- unreg_thermal:
-diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 5609108b..e0210c3e 100644
---- a/mt7915/mac.c
-+++ b/mt7915/mac.c
-@@ -3,6 +3,7 @@
- 
- #include <linux/etherdevice.h>
- #include <linux/timekeeping.h>
-+#include <linux/pci.h>
- #include "mt7915.h"
- #include "../dma.h"
- #include "mac.h"
-@@ -1331,85 +1332,187 @@ mt7915_update_beacons(struct mt7915_dev *dev)
- 		mt7915_update_vif_beacon, mphy_ext->hw);
- }
- 
--static void
--mt7915_dma_reset(struct mt7915_dev *dev)
-+void mt7915_tx_token_put(struct mt7915_dev *dev)
- {
--	struct mt76_phy *mphy_ext = dev->mt76.phys[MT_BAND1];
--	u32 hif1_ofs = MT_WFDMA0_PCIE1(0) - MT_WFDMA0(0);
--	int i;
-+	struct mt76_txwi_cache *txwi;
-+	int id;
-+
-+	spin_lock_bh(&dev->mt76.token_lock);
-+	idr_for_each_entry(&dev->mt76.token, txwi, id) {
-+		mt7915_txwi_free(dev, txwi, NULL, NULL);
-+		dev->mt76.token_count--;
-+	}
-+	spin_unlock_bh(&dev->mt76.token_lock);
-+	idr_destroy(&dev->mt76.token);
-+}
-+
-+static int
-+mt7915_mac_reset(struct mt7915_dev *dev)
-+{
-+	struct mt7915_phy *phy2;
-+	struct mt76_phy *ext_phy;
-+	struct mt76_dev *mdev = &dev->mt76;
-+	int i, ret;
-+	u32 irq_mask;
- 
--	mt76_clear(dev, MT_WFDMA0_GLO_CFG,
--		   MT_WFDMA0_GLO_CFG_TX_DMA_EN |
--		   MT_WFDMA0_GLO_CFG_RX_DMA_EN);
-+	ext_phy = dev->mt76.phys[MT_BAND1];
-+	phy2 = ext_phy ? ext_phy->priv : NULL;
- 
--	if (is_mt7915(&dev->mt76))
--		mt76_clear(dev, MT_WFDMA1_GLO_CFG,
--			   MT_WFDMA1_GLO_CFG_TX_DMA_EN |
--			   MT_WFDMA1_GLO_CFG_RX_DMA_EN);
- 	if (dev->hif2) {
--		mt76_clear(dev, MT_WFDMA0_GLO_CFG + hif1_ofs,
--			   MT_WFDMA0_GLO_CFG_TX_DMA_EN |
--			   MT_WFDMA0_GLO_CFG_RX_DMA_EN);
--
--		if (is_mt7915(&dev->mt76))
--			mt76_clear(dev, MT_WFDMA1_GLO_CFG + hif1_ofs,
--				   MT_WFDMA1_GLO_CFG_TX_DMA_EN |
--				   MT_WFDMA1_GLO_CFG_RX_DMA_EN);
-+		mt76_wr(dev, MT_INT1_MASK_CSR, 0x0);
-+		mt76_wr(dev, MT_INT1_SOURCE_CSR, ~0);
- 	}
- 
--	usleep_range(1000, 2000);
-+	if (dev_is_pci(mdev->dev)) {
-+		mt76_wr(dev, MT_PCIE_MAC_INT_ENABLE, 0x0);
-+		if (dev->hif2)
-+			mt76_wr(dev, MT_PCIE1_MAC_INT_ENABLE, 0x0);
-+	}
- 
--	for (i = 0; i < __MT_TXQ_MAX; i++) {
--		mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[i], true);
--		if (mphy_ext)
--			mt76_queue_tx_cleanup(dev, mphy_ext->q_tx[i], true);
-+	set_bit(MT76_RESET, &dev->mphy.state);
-+	set_bit(MT76_MCU_RESET, &dev->mphy.state);
-+	wake_up(&dev->mt76.mcu.wait);
-+	if (ext_phy) {
-+		set_bit(MT76_RESET, &ext_phy->state);
-+		set_bit(MT76_MCU_RESET, &ext_phy->state);
- 	}
- 
--	for (i = 0; i < __MT_MCUQ_MAX; i++)
--		mt76_queue_tx_cleanup(dev, dev->mt76.q_mcu[i], true);
-+	/* lock/unlock all queues to ensure that no tx is pending */
-+	mt76_txq_schedule_all(&dev->mphy);
-+	if (ext_phy)
-+		mt76_txq_schedule_all(ext_phy);
- 
--	mt76_for_each_q_rx(&dev->mt76, i)
--		mt76_queue_rx_reset(dev, i);
-+	/* disable all tx/rx napi */
-+	mt76_worker_disable(&dev->mt76.tx_worker);
-+	mt76_for_each_q_rx(mdev, i) {
-+		if (mdev->q_rx[i].ndesc)
-+			napi_disable(&dev->mt76.napi[i]);
-+	}
-+	napi_disable(&dev->mt76.tx_napi);
- 
--	mt76_tx_status_check(&dev->mt76, true);
-+	/* token reinit */
-+	mt7915_tx_token_put(dev);
-+	idr_init(&dev->mt76.token);
- 
--	/* re-init prefetch settings after reset */
--	mt7915_dma_prefetch(dev);
-+	mt7915_dma_reset(dev, true);
-+
-+	local_bh_disable();
-+	mt76_for_each_q_rx(mdev, i) {
-+		if (mdev->q_rx[i].ndesc) {
-+			napi_enable(&dev->mt76.napi[i]);
-+			napi_schedule(&dev->mt76.napi[i]);
-+		}
-+	}
-+	local_bh_enable();
-+	clear_bit(MT76_MCU_RESET, &dev->mphy.state);
-+	clear_bit(MT76_STATE_MCU_RUNNING, &dev->mphy.state);
-+
-+	mt76_wr(dev, MT_INT_MASK_CSR, dev->mt76.mmio.irqmask);
-+	mt76_wr(dev, MT_INT_SOURCE_CSR, ~0);
- 
--	mt76_set(dev, MT_WFDMA0_GLO_CFG,
--		 MT_WFDMA0_GLO_CFG_TX_DMA_EN | MT_WFDMA0_GLO_CFG_RX_DMA_EN);
--	if (is_mt7915(&dev->mt76))
--		mt76_set(dev, MT_WFDMA1_GLO_CFG,
--			 MT_WFDMA1_GLO_CFG_TX_DMA_EN |
--			 MT_WFDMA1_GLO_CFG_RX_DMA_EN |
--			 MT_WFDMA1_GLO_CFG_OMIT_TX_INFO |
--			 MT_WFDMA1_GLO_CFG_OMIT_RX_INFO);
- 	if (dev->hif2) {
--		mt76_set(dev, MT_WFDMA0_GLO_CFG + hif1_ofs,
--			 MT_WFDMA0_GLO_CFG_TX_DMA_EN |
--			 MT_WFDMA0_GLO_CFG_RX_DMA_EN);
--
--		if (is_mt7915(&dev->mt76))
--			mt76_set(dev, MT_WFDMA1_GLO_CFG + hif1_ofs,
--				 MT_WFDMA1_GLO_CFG_TX_DMA_EN |
--				 MT_WFDMA1_GLO_CFG_RX_DMA_EN |
--				 MT_WFDMA1_GLO_CFG_OMIT_TX_INFO |
--				 MT_WFDMA1_GLO_CFG_OMIT_RX_INFO);
-+		mt76_wr(dev, MT_INT1_MASK_CSR, irq_mask);
-+		mt76_wr(dev, MT_INT1_SOURCE_CSR, ~0);
-+	}
-+	if (dev_is_pci(mdev->dev)) {
-+		mt76_wr(dev, MT_PCIE_MAC_INT_ENABLE, 0xff);
-+		if (dev->hif2)
-+			mt76_wr(dev, MT_PCIE1_MAC_INT_ENABLE, 0xff);
-+	}
-+
-+	/* load firmware */
-+	ret = mt7915_run_firmware(dev);
-+	if (ret)
-+		goto out;
-+
-+	/* set the necessary init items */
-+	ret = mt7915_mcu_set_eeprom(dev, dev->flash_mode);
-+	if (ret)
-+		goto out;
-+
-+	mt7915_mac_init(dev);
-+	mt7915_init_txpower(dev, &dev->mphy.sband_2g.sband);
-+	mt7915_init_txpower(dev, &dev->mphy.sband_5g.sband);
-+	ret = mt7915_txbf_init(dev);
-+
-+	if (test_bit(MT76_STATE_RUNNING, &dev->mphy.state)) {
-+		ret = __mt7915_start(dev->mphy.hw);
-+		if (ret)
-+			goto out;
- 	}
-+
-+	if (ext_phy && test_bit(MT76_STATE_RUNNING, &ext_phy->state)) {
-+		ret = __mt7915_start(ext_phy->hw);
-+		if (ret)
-+			goto out;
-+	}
-+
-+out:
-+	/* reset done */
-+	clear_bit(MT76_RESET, &dev->mphy.state);
-+	if (phy2)
-+		clear_bit(MT76_RESET, &phy2->mt76->state);
-+
-+	local_bh_disable();
-+	napi_enable(&dev->mt76.tx_napi);
-+	napi_schedule(&dev->mt76.tx_napi);
-+	local_bh_enable();
-+
-+	mt76_worker_enable(&dev->mt76.tx_worker);
-+
-+	return ret;
- }
- 
--void mt7915_tx_token_put(struct mt7915_dev *dev)
-+static void
-+mt7915_mac_full_reset(struct mt7915_dev *dev)
- {
--	struct mt76_txwi_cache *txwi;
--	int id;
-+	struct mt7915_phy *phy2;
-+	struct mt76_phy *ext_phy;
-+	int i;
- 
--	spin_lock_bh(&dev->mt76.token_lock);
--	idr_for_each_entry(&dev->mt76.token, txwi, id) {
--		mt7915_txwi_free(dev, txwi, NULL, NULL);
--		dev->mt76.token_count--;
-+	ext_phy = dev->mt76.phys[MT_BAND1];
-+	phy2 = ext_phy ? ext_phy->priv : NULL;
-+
-+	dev->ser.hw_full_reset = true;
-+	if (READ_ONCE(dev->reset_state) & MT_MCU_CMD_WA_WDT)
-+		dev->ser.wf_reset_wa_count++;
-+	else
-+		dev->ser.wf_reset_wm_count++;
-+
-+	wake_up(&dev->mt76.mcu.wait);
-+	ieee80211_stop_queues(mt76_hw(dev));
-+	if (ext_phy)
-+		ieee80211_stop_queues(ext_phy->hw);
-+
-+	cancel_delayed_work_sync(&dev->mphy.mac_work);
-+	if (ext_phy)
-+		cancel_delayed_work_sync(&ext_phy->mac_work);
-+
-+	mutex_lock(&dev->mt76.mutex);
-+	for (i = 0; i < 10; i++) {
-+		if (!mt7915_mac_reset(dev))
-+			break;
- 	}
--	spin_unlock_bh(&dev->mt76.token_lock);
--	idr_destroy(&dev->mt76.token);
-+	mutex_unlock(&dev->mt76.mutex);
-+
-+	if (i == 10)
-+		dev_err(dev->mt76.dev, "chip full reset failed\n");
-+
-+	ieee80211_restart_hw(mt76_hw(dev));
-+	if (ext_phy)
-+		ieee80211_restart_hw(ext_phy->hw);
-+
-+	ieee80211_wake_queues(mt76_hw(dev));
-+	if (ext_phy)
-+		ieee80211_wake_queues(ext_phy->hw);
-+
-+	dev->ser.hw_full_reset = false;
-+	ieee80211_queue_delayed_work(mt76_hw(dev), &dev->mphy.mac_work,
-+				     MT7915_WATCHDOG_TIME);
-+	if (ext_phy)
-+		ieee80211_queue_delayed_work(ext_phy->hw,
-+					     &ext_phy->mac_work,
-+					     MT7915_WATCHDOG_TIME);
- }
- 
- /* system error recovery */
-@@ -1424,6 +1527,36 @@ void mt7915_mac_reset_work(struct work_struct *work)
- 	ext_phy = dev->mt76.phys[MT_BAND1];
- 	phy2 = ext_phy ? ext_phy->priv : NULL;
- 
-+	/* chip full reset */
-+	if (dev->ser.reset_type == SER_TYPE_FULL_RESET) {
-+		u32 intr;
-+
-+		/* disable WA/WM WDT */
-+		intr = mt76_rr(dev, MT_WFDMA0_MCU_HOST_INT_ENA);
-+		intr &= ~MT_MCU_CMD_WDT_MASK;
-+		mt76_set(dev, MT_WFDMA0_MCU_HOST_INT_ENA, intr);
-+
-+		mt7915_mac_full_reset(dev);
-+
-+		/* enable the mcu irq*/
-+		mt7915_irq_enable(dev, MT_INT_MCU_CMD);
-+		mt7915_irq_disable(dev, 0);
-+
-+		/* re-enable WA/WM WDT */
-+		intr = mt76_rr(dev, MT_WFDMA0_MCU_HOST_INT_ENA);
-+		intr |= MT_MCU_CMD_WDT_MASK;
-+		mt76_set(dev, MT_WFDMA0_MCU_HOST_INT_ENA, intr);
-+
-+		dev->reset_state = MT_MCU_CMD_NORMAL_STATE;
-+		dev->ser.reset_type = SER_TYPE_NONE;
-+		dev_info(dev->mt76.dev, "SER: chip full reset completed, WM %d, WA %d\n",
-+			 dev->ser.wf_reset_wm_count,
-+			 dev->ser.wf_reset_wa_count);
-+		return;
-+	}
-+
-+	/* chip partial reset */
-+	dev->ser.reset_type = SER_TYPE_NONE;
- 	if (!(READ_ONCE(dev->reset_state) & MT_MCU_CMD_STOP_DMA))
- 		return;
- 
-@@ -1449,7 +1582,7 @@ void mt7915_mac_reset_work(struct work_struct *work)
- 	mt76_wr(dev, MT_MCU_INT_EVENT, MT_MCU_INT_EVENT_DMA_STOPPED);
- 
- 	if (mt7915_wait_reset_state(dev, MT_MCU_CMD_RESET_DONE)) {
--		mt7915_dma_reset(dev);
-+		mt7915_dma_reset(dev, false);
- 
- 		mt7915_tx_token_put(dev);
- 		idr_init(&dev->mt76.token);
-@@ -1498,6 +1631,34 @@ void mt7915_mac_reset_work(struct work_struct *work)
- 					     MT7915_WATCHDOG_TIME);
- }
- 
-+void mt7915_reset(struct mt7915_dev *dev)
-+{
-+	if (!dev->ser.hw_init_done)
-+		return;
-+
-+	if (dev->ser.hw_full_reset)
-+		return;
-+
-+	/* wm/wa exception: do full recovery */
-+	if (READ_ONCE(dev->reset_state) & MT_MCU_CMD_WDT_MASK) {
-+		dev_info(dev->mt76.dev, "SER: chip full recovery start, WM %d, WA %d\n",
-+			 dev->ser.wf_reset_wm_count,
-+			 dev->ser.wf_reset_wa_count);
-+
-+		dev->ser.reset_type = SER_TYPE_FULL_RESET;
-+
-+		mt7915_irq_disable(dev, MT_INT_MCU_CMD);
-+		queue_work(dev->mt76.wq, &dev->reset_work);
-+		return;
-+	}
-+
-+	dev_info(dev->mt76.dev, "SER: chip partial recovery, reset_state(0x%08X)\n",
-+		READ_ONCE(dev->reset_state));
-+	dev->ser.reset_type = SER_TYPE_PARTIAL_RESET;
-+	queue_work(dev->mt76.wq, &dev->reset_work);
-+	wake_up(&dev->reset_wait);
-+}
-+
- void mt7915_mac_update_stats(struct mt7915_phy *phy)
- {
- 	struct mt7915_dev *dev = phy->dev;
-diff --git a/mt7915/main.c b/mt7915/main.c
-index abfdc729..98dce0f4 100644
---- a/mt7915/main.c
-+++ b/mt7915/main.c
-@@ -20,17 +20,13 @@ static bool mt7915_dev_running(struct mt7915_dev *dev)
- 	return phy && test_bit(MT76_STATE_RUNNING, &phy->mt76->state);
- }
- 
--static int mt7915_start(struct ieee80211_hw *hw)
-+int __mt7915_start(struct ieee80211_hw *hw)
- {
- 	struct mt7915_dev *dev = mt7915_hw_dev(hw);
- 	struct mt7915_phy *phy = mt7915_hw_phy(hw);
- 	bool running;
- 	int ret;
- 
--	flush_work(&dev->init_work);
--
--	mutex_lock(&dev->mt76.mutex);
--
- 	running = mt7915_dev_running(dev);
- 
- 	if (!running) {
-@@ -84,6 +80,18 @@ static int mt7915_start(struct ieee80211_hw *hw)
- 		mt7915_mac_reset_counters(phy);
- 
- out:
-+	return ret;
-+}
-+
-+static int mt7915_start(struct ieee80211_hw *hw)
-+{
-+	struct mt7915_dev *dev = mt7915_hw_dev(hw);
-+	int ret;
-+
-+	flush_work(&dev->init_work);
-+
-+	mutex_lock(&dev->mt76.mutex);
-+	ret = __mt7915_start(hw);
- 	mutex_unlock(&dev->mt76.mutex);
- 
- 	return ret;
-@@ -95,6 +103,7 @@ static void mt7915_stop(struct ieee80211_hw *hw)
- 	struct mt7915_phy *phy = mt7915_hw_phy(hw);
- 
- 	cancel_delayed_work_sync(&phy->mt76->mac_work);
-+	cancel_work_sync(&dev->reset_work);
- 
- 	mutex_lock(&dev->mt76.mutex);
- 
-diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 8731f7d0..79844323 100644
---- a/mt7915/mcu.c
-+++ b/mt7915/mcu.c
-@@ -150,19 +150,90 @@ mt7915_mcu_set_sta_ht_mcs(struct ieee80211_sta *sta, u8 *ht_mcs,
- 		ht_mcs[nss] = sta->ht_cap.mcs.rx_mask[nss] & mask[nss];
- }
- 
-+static int
-+mt7915_fw_exception_chk(struct mt7915_dev *dev)
-+{
-+	u32 reg_val;
-+
-+	reg_val = mt76_rr(dev, MT_EXCEPTION_ADDR);
-+
-+	if (is_mt7915(&dev->mt76))
-+		reg_val >>= 8;
-+
-+	return !!(reg_val & 0xff);
-+}
-+
-+static void
-+mt7915_fw_heart_beat_chk(struct mt7915_dev *dev)
-+{
-+#define WM_TIMEOUT_COUNT_CHECK 5
-+#define WM_HANG_COUNT_CHECK 9
-+	static u32 cidx_rec[5], didx_rec[5];
-+	u32 cnt, cidx, didx, queue;
-+	u32 idx, i;
-+
-+	if (dev->ser.hw_full_reset)
-+		return;
-+
-+	if (dev->ser.cmd_fail_cnt >= WM_TIMEOUT_COUNT_CHECK) {
-+		cnt = mt76_rr(dev, WF_WFDMA_MEM_DMA_RX_RING_CTL + 4);
-+		cidx = mt76_rr(dev, WF_WFDMA_MEM_DMA_RX_RING_CTL + 8);
-+		didx = mt76_rr(dev, WF_WFDMA_MEM_DMA_RX_RING_CTL + 12);
-+		queue = (didx > cidx) ?
-+			(didx - cidx - 1) : (didx - cidx + cnt - 1);
-+
-+		idx = (dev->ser.cmd_fail_cnt - WM_TIMEOUT_COUNT_CHECK) % 5;
-+		cidx_rec[idx] = cidx;
-+		didx_rec[idx] = didx;
-+
-+		if ((cnt - 1) == queue &&
-+		    dev->ser.cmd_fail_cnt >= WM_HANG_COUNT_CHECK) {
-+
-+			for (i = 0; i < 5; i++) {
-+				if (cidx_rec[i] != cidx ||
-+				    didx_rec[i] != didx)
-+					return;
-+			}
-+			dev_err(dev->mt76.dev, "detect mem dma hang!\n");
-+			if (dev->ser.reset_enable) {
-+				dev->reset_state |= MT_MCU_CMD_WDT_MASK;
-+				mt7915_reset(dev);
-+			}
-+			dev->ser.cmd_fail_cnt = 0;
-+		}
-+	}
-+}
-+
- static int
- mt7915_mcu_parse_response(struct mt76_dev *mdev, int cmd,
- 			  struct sk_buff *skb, int seq)
- {
-+	struct mt7915_dev *dev = container_of(mdev, struct mt7915_dev, mt76);
- 	struct mt76_connac2_mcu_rxd *rxd;
- 	int ret = 0;
- 
- 	if (!skb) {
- 		dev_err(mdev->dev, "Message %08x (seq %d) timeout\n",
- 			cmd, seq);
-+
-+		dev->ser.cmd_fail_cnt++;
-+
-+		if (dev->ser.cmd_fail_cnt < 5) {
-+			int exp_type = mt7915_fw_exception_chk(dev);
-+
-+			dev_err(mdev->dev, "Fw is status(%d)\n", exp_type);
-+			if (exp_type && dev->ser.reset_enable) {
-+				dev->reset_state |= MT_MCU_CMD_WDT_MASK;
-+				mt7915_reset(dev);
-+			}
-+		}
-+		mt7915_fw_heart_beat_chk(dev);
-+
- 		return -ETIMEDOUT;
- 	}
- 
-+	dev->ser.cmd_fail_cnt = 0;
-+
- 	rxd = (struct mt76_connac2_mcu_rxd *)skb->data;
- 	if (seq != rxd->seq)
- 		return -EAGAIN;
-@@ -2268,18 +2339,10 @@ mt7915_mcu_init_rx_airtime(struct mt7915_dev *dev)
- 				 sizeof(req), true);
- }
- 
--int mt7915_mcu_init(struct mt7915_dev *dev)
-+int mt7915_run_firmware(struct mt7915_dev *dev)
- {
--	static const struct mt76_mcu_ops mt7915_mcu_ops = {
--		.headroom = sizeof(struct mt76_connac2_mcu_txd),
--		.mcu_skb_send_msg = mt7915_mcu_send_message,
--		.mcu_parse_response = mt7915_mcu_parse_response,
--		.mcu_restart = mt76_connac_mcu_restart,
--	};
- 	int ret;
- 
--	dev->mt76.mcu_ops = &mt7915_mcu_ops;
--
- 	/* force firmware operation mode into normal state,
- 	 * which should be set before firmware download stage.
- 	 */
-@@ -2328,6 +2391,20 @@ int mt7915_mcu_init(struct mt7915_dev *dev)
- 				 MCU_WA_PARAM_RED, 0, 0);
- }
- 
-+int mt7915_mcu_init(struct mt7915_dev *dev)
-+{
-+	static const struct mt76_mcu_ops mt7915_mcu_ops = {
-+		.headroom = sizeof(struct mt76_connac2_mcu_txd),
-+		.mcu_skb_send_msg = mt7915_mcu_send_message,
-+		.mcu_parse_response = mt7915_mcu_parse_response,
-+		.mcu_restart = mt76_connac_mcu_restart,
-+	};
-+
-+	dev->mt76.mcu_ops = &mt7915_mcu_ops;
-+
-+	return mt7915_run_firmware(dev);
-+}
-+
- void mt7915_mcu_exit(struct mt7915_dev *dev)
- {
- 	__mt76_mcu_restart(&dev->mt76);
-diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index aab1a6a3..c4850644 100644
---- a/mt7915/mcu.h
-+++ b/mt7915/mcu.h
-@@ -453,8 +453,9 @@ enum {
- 
- enum {
- 	SER_QUERY,
-+	SER_SET,
- 	/* recovery */
--	SER_SET_RECOVER_L1,
-+	SER_SET_RECOVER_L1 = 1,
- 	SER_SET_RECOVER_L2,
- 	SER_SET_RECOVER_L3_RX_ABORT,
- 	SER_SET_RECOVER_L3_TX_ABORT,
-diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 9c2c5086..2e73bd79 100644
---- a/mt7915/mmio.c
-+++ b/mt7915/mmio.c
-@@ -29,6 +29,7 @@ static const u32 mt7915_reg[] = {
- 	[SWDEF_BASE_ADDR]	= 0x41f200,
- 	[TXQ_WED_RING_BASE]	= 0xd7300,
- 	[RXQ_WED_RING_BASE]	= 0xd7410,
-+	[EXCEPTION_BASE_ADDR]	= 0x219848,
- };
- 
- static const u32 mt7916_reg[] = {
-@@ -47,6 +48,7 @@ static const u32 mt7916_reg[] = {
- 	[SWDEF_BASE_ADDR]	= 0x411400,
- 	[TXQ_WED_RING_BASE]	= 0xd7300,
- 	[RXQ_WED_RING_BASE]	= 0xd7410,
-+	[EXCEPTION_BASE_ADDR]	= 0x022050BC,
- };
- 
- static const u32 mt7986_reg[] = {
-@@ -65,6 +67,7 @@ static const u32 mt7986_reg[] = {
- 	[SWDEF_BASE_ADDR]	= 0x411400,
- 	[TXQ_WED_RING_BASE]	= 0x24420,
- 	[RXQ_WED_RING_BASE]	= 0x24520,
-+	[EXCEPTION_BASE_ADDR]	= 0x02204FFC,
- };
- 
- static const u32 mt7915_offs[] = {
-@@ -748,10 +751,9 @@ static void mt7915_irq_tasklet(struct tasklet_struct *t)
- 		u32 val = mt76_rr(dev, MT_MCU_CMD);
- 
- 		mt76_wr(dev, MT_MCU_CMD, val);
--		if (val & MT_MCU_CMD_ERROR_MASK) {
-+		if (val & (MT_MCU_CMD_ERROR_MASK | MT_MCU_CMD_WDT_MASK)) {
- 			dev->reset_state = val;
--			queue_work(dev->mt76.wq, &dev->reset_work);
--			wake_up(&dev->reset_wait);
-+			mt7915_reset(dev);
- 		}
- 	}
- }
-diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 93afa3d2..6868813a 100644
---- a/mt7915/mt7915.h
-+++ b/mt7915/mt7915.h
-@@ -350,6 +350,15 @@ struct mt7915_dev {
- 	struct work_struct reset_work;
- 	wait_queue_head_t reset_wait;
- 	u32 reset_state;
-+	struct {
-+		bool hw_full_reset:1;
-+		bool hw_init_done:1;
-+		bool reset_enable:1;
-+		u32 reset_type;
-+		u32 cmd_fail_cnt;
-+		u32 wf_reset_wm_count;
-+		u32 wf_reset_wa_count;
-+	}ser;
- 
- 	struct list_head sta_rc_list;
- 	struct list_head sta_poll_list;
-@@ -414,6 +423,12 @@ enum {
- 	__MT_WFDMA_MAX,
- };
- 
-+enum {
-+	SER_TYPE_NONE,
-+	SER_TYPE_PARTIAL_RESET,
-+	SER_TYPE_FULL_RESET,
-+};
-+
- enum {
- 	MT_RX_SEL0,
- 	MT_RX_SEL1,
-@@ -512,6 +527,14 @@ s8 mt7915_eeprom_get_power_delta(struct mt7915_dev *dev, int band);
- int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2);
- void mt7915_dma_prefetch(struct mt7915_dev *dev);
- void mt7915_dma_cleanup(struct mt7915_dev *dev);
-+void mt7915_reset(struct mt7915_dev *dev);
-+int mt7915_dma_reset(struct mt7915_dev *dev, bool force);
-+int __mt7915_start(struct ieee80211_hw *hw);
-+void mt7915_init_txpower(struct mt7915_dev *dev,
-+		    struct ieee80211_supported_band *sband);
-+int mt7915_txbf_init(struct mt7915_dev *dev);
-+void mt7915_mac_init(struct mt7915_dev *dev);
-+int mt7915_run_firmware(struct mt7915_dev *dev);
- int mt7915_mcu_init(struct mt7915_dev *dev);
- int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
- 			       struct mt7915_vif *mvif,
-diff --git a/mt7915/regs.h b/mt7915/regs.h
-index 2e445373..3f283a83 100644
---- a/mt7915/regs.h
-+++ b/mt7915/regs.h
-@@ -28,6 +28,7 @@ enum reg_rev {
- 	SWDEF_BASE_ADDR,
- 	TXQ_WED_RING_BASE,
- 	RXQ_WED_RING_BASE,
-+	EXCEPTION_BASE_ADDR,
- 	__MT_REG_MAX,
- };
- 
-@@ -110,6 +111,11 @@ enum offs_rev {
- #define __REG(id)			(dev->reg.reg_rev[(id)])
- #define __OFFS(id)			(dev->reg.offs_rev[(id)])
- 
-+/* MEM WFDMA */
-+#define WF_WFDMA_MEM_DMA		0x58000000
-+
-+#define WF_WFDMA_MEM_DMA_RX_RING_CTL	(WF_WFDMA_MEM_DMA + (0x510))
-+
- /* MCU WFDMA0 */
- #define MT_MCU_WFDMA0_BASE		0x2000
- #define MT_MCU_WFDMA0(ofs)		(MT_MCU_WFDMA0_BASE + (ofs))
-@@ -565,6 +571,10 @@ enum offs_rev {
- #define MT_WFDMA0_PRI_DLY_INT_CFG1	MT_WFDMA0(0x2f4)
- #define MT_WFDMA0_PRI_DLY_INT_CFG2	MT_WFDMA0(0x2f8)
- 
-+#define MT_WFDMA0_MCU_HOST_INT_ENA	MT_WFDMA0(0x1f4)
-+#define MT_WFDMA0_MT_WA_WDT_INT		BIT(31)
-+#define MT_WFDMA0_MT_WM_WDT_INT		BIT(30)
-+
- /* WFDMA1 */
- #define MT_WFDMA1_BASE			0xd5000
- #define MT_WFDMA1(ofs)			(MT_WFDMA1_BASE + (ofs))
-@@ -721,6 +731,10 @@ enum offs_rev {
- #define MT_MCU_CMD_NORMAL_STATE		BIT(5)
- #define MT_MCU_CMD_ERROR_MASK		GENMASK(5, 1)
- 
-+#define MT_MCU_CMD_WA_WDT		BIT(31)
-+#define MT_MCU_CMD_WM_WDT		BIT(30)
-+#define MT_MCU_CMD_WDT_MASK		GENMASK(31, 30)
-+
- /* TOP RGU */
- #define MT_TOP_RGU_BASE			0x18000000
- #define MT_TOP_PWR_CTRL			(MT_TOP_RGU_BASE + (0x0))
-@@ -996,6 +1010,8 @@ enum offs_rev {
- #define MT_CPU_UTIL_PEAK_IDLE_CNT	MT_CPU_UTIL(0x0c)
- #define MT_CPU_UTIL_CTRL		MT_CPU_UTIL(0x1c)
- 
-+#define MT_EXCEPTION_ADDR		__REG(EXCEPTION_BASE_ADDR)
-+
- /* LED */
- #define MT_LED_TOP_BASE			0x18013000
- #define MT_LED_PHYS(_n)			(MT_LED_TOP_BASE + (_n))
--- 
-2.25.1
-
diff --git a/recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch b/recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch
similarity index 77%
rename from recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch
rename to recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch
index a473373..68d31f7 100644
--- a/recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1006-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch
@@ -1,7 +1,7 @@
-From eaa7bb6b3e47af84399c5bb3a421ac23a8c0b96d Mon Sep 17 00:00:00 2001
+From 310c3bf59cf9eea521ee8d75bb4603af0e97a9d9 Mon Sep 17 00:00:00 2001
 From: MeiChia Chiu <meichia.chiu@mediatek.com>
 Date: Fri, 27 May 2022 15:51:48 +0800
-Subject: [PATCH 1007/1009] mt76: mt7915:add support for runtime set in-band
+Subject: [PATCH 1006/1008] mt76: mt7915:add support for runtime set in-band
  discovery
 
 Signed-off-by: MeiChia Chiu <MeiChia.Chiu@mediatek.com>
@@ -10,10 +10,10 @@
  1 file changed, 2 insertions(+), 3 deletions(-)
 
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 79844323..d36bcd0a 100644
+index 1bd46cc4..9117c9e2 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2022,8 +2022,7 @@ mt7915_mcu_beacon_inband_discov(struct mt7915_dev *dev, struct ieee80211_vif *vi
+@@ -1951,8 +1951,7 @@ mt7915_mcu_beacon_inband_discov(struct mt7915_dev *dev, struct ieee80211_vif *vi
  	u8 *buf, interval;
  	int len;
  
@@ -23,7 +23,7 @@
  		interval = vif->bss_conf.fils_discovery.max_interval;
  		skb = ieee80211_get_fils_discovery_tmpl(hw, vif);
  	} else if (changed & BSS_CHANGED_UNSOL_BCAST_PROBE_RESP &&
-@@ -2058,7 +2057,7 @@ mt7915_mcu_beacon_inband_discov(struct mt7915_dev *dev, struct ieee80211_vif *vi
+@@ -1987,7 +1986,7 @@ mt7915_mcu_beacon_inband_discov(struct mt7915_dev *dev, struct ieee80211_vif *vi
  	discov->tx_type = !!(changed & BSS_CHANGED_FILS_DISCOVERY);
  	discov->tx_interval = interval;
  	discov->prob_rsp_len = cpu_to_le16(MT_TXD_SIZE + skb->len);
@@ -33,5 +33,5 @@
  	buf = (u8 *)tlv + sizeof(*discov);
  
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch b/recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch
similarity index 92%
rename from recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch
rename to recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch
index 0d6a14d..f6045cf 100644
--- a/recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1007-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch
@@ -1,7 +1,7 @@
-From db5bbdab6a3a2e72c8309f06dff31115e51fd874 Mon Sep 17 00:00:00 2001
+From 3258b1f670c506b036cab0d06d87708933f7cd83 Mon Sep 17 00:00:00 2001
 From: MeiChia Chiu <meichia.chiu@mediatek.com>
 Date: Wed, 22 Jun 2022 10:53:43 +0800
-Subject: [PATCH 1008/1009] mt76: mt7915: add mt76 vendor muru onoff command
+Subject: [PATCH 1007/1008] mt76: mt7915: add mt76 vendor muru onoff command
 
 ---
  mt7915/mcu.c    |  7 +++++++
@@ -11,10 +11,10 @@
  4 files changed, 63 insertions(+)
 
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index d36bcd0a..bcecc5e3 100644
+index 9117c9e2..2a18dd53 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -3670,6 +3670,13 @@ void mt7915_set_wireless_vif(void *data, u8 *mac, struct ieee80211_vif *vif)
+@@ -3614,6 +3614,13 @@ void mt7915_set_wireless_vif(void *data, u8 *mac, struct ieee80211_vif *vif)
  		if (val == 0)
  			dev->dbg.muru_onoff = MUMIMO_DL_CERT | MUMIMO_DL;
  		break;
@@ -29,10 +29,10 @@
  }
  
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index c4850644..0a77ad0d 100644
+index c45486fd..8eaf984a 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -403,6 +403,7 @@ enum {
+@@ -405,6 +405,7 @@ enum {
  #ifdef CONFIG_MTK_VENDOR
  	RATE_PARAM_FIXED_MIMO = 30,
  	RATE_PARAM_FIXED_OFDMA = 31,
@@ -139,5 +139,5 @@
  	MTK_VENDOR_ATTR_RFEATURE_CTRL_UNSPEC,
  
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1009-mt76-mt7915-add-fw_version-dump.patch b/recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-fw_version-dump.patch
similarity index 87%
rename from recipes-wifi/linux-mt76/files/patches/1009-mt76-mt7915-add-fw_version-dump.patch
rename to recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-fw_version-dump.patch
index 89e3e3e..145822e 100644
--- a/recipes-wifi/linux-mt76/files/patches/1009-mt76-mt7915-add-fw_version-dump.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1008-mt76-mt7915-add-fw_version-dump.patch
@@ -1,7 +1,7 @@
-From 3eaaa3c218dd75d14dea44f903e5d689ac9dd994 Mon Sep 17 00:00:00 2001
+From 05dd4dcaf63a2026f920cd4936c0a12c8b6303ae Mon Sep 17 00:00:00 2001
 From: Evelyn Tsai <evelyn.tsai@mediatek.com>
 Date: Wed, 17 Aug 2022 13:40:24 +0800
-Subject: [PATCH 1009/1009] mt76: mt7915: add fw_version dump
+Subject: [PATCH 1008/1008] mt76: mt7915: add fw_version dump
 
 ---
  mt76.h               |  4 ++++
@@ -10,7 +10,7 @@
  3 files changed, 32 insertions(+)
 
 diff --git a/mt76.h b/mt76.h
-index aef60066..fac1dfb7 100644
+index 1b468ccc..3a177fff 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -823,6 +823,10 @@ struct mt76_dev {
@@ -25,10 +25,10 @@
  
  struct mt76_power_limits {
 diff --git a/mt76_connac_mcu.c b/mt76_connac_mcu.c
-index ed6c9ebb..be2a2de1 100644
+index dfec416e..7ab491d6 100644
 --- a/mt76_connac_mcu.c
 +++ b/mt76_connac_mcu.c
-@@ -2889,6 +2889,9 @@ int mt76_connac2_load_ram(struct mt76_dev *dev, const char *fw_wm,
+@@ -2904,6 +2904,9 @@ int mt76_connac2_load_ram(struct mt76_dev *dev, const char *fw_wm,
  		 sizeof(dev->hw->wiphy->fw_version),
  		 "%.10s-%.15s", hdr->fw_ver, hdr->build_date);
  
@@ -38,7 +38,7 @@
  	release_firmware(fw);
  
  	if (!fw_wa)
-@@ -2914,6 +2917,9 @@ int mt76_connac2_load_ram(struct mt76_dev *dev, const char *fw_wm,
+@@ -2929,6 +2932,9 @@ int mt76_connac2_load_ram(struct mt76_dev *dev, const char *fw_wm,
  		goto out;
  	}
  
@@ -48,7 +48,7 @@
  	snprintf(dev->hw->wiphy->fw_version,
  		 sizeof(dev->hw->wiphy->fw_version),
  		 "%.10s-%.15s", hdr->fw_ver, hdr->build_date);
-@@ -2984,6 +2990,9 @@ int mt76_connac2_load_patch(struct mt76_dev *dev, const char *fw_name)
+@@ -2999,6 +3005,9 @@ int mt76_connac2_load_patch(struct mt76_dev *dev, const char *fw_name)
  	dev_info(dev->dev, "HW/SW Version: 0x%x, Build Time: %.16s\n",
  		 be32_to_cpu(hdr->hw_sw_ver), hdr->build_date);
  
@@ -96,5 +96,5 @@
  }
  #endif
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1111-mt76-testmode-additional-supports.patch b/recipes-wifi/linux-mt76/files/patches/1111-mt76-testmode-additional-supports.patch
index 25042b2..3ca4b85 100644
--- a/recipes-wifi/linux-mt76/files/patches/1111-mt76-testmode-additional-supports.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1111-mt76-testmode-additional-supports.patch
@@ -1,7 +1,7 @@
-From ef88a8764755afe4db6617a640ee6edd3b47e86d Mon Sep 17 00:00:00 2001
+From 8758539453946b5e3941f2e46d7ae4f933823dd2 Mon Sep 17 00:00:00 2001
 From: Shayne Chen <shayne.chen@mediatek.com>
 Date: Thu, 21 Apr 2022 15:43:19 +0800
-Subject: [PATCH 1111/1127] mt76: testmode: additional supports
+Subject: [PATCH 1111/1128] mt76: testmode: additional supports
 
 Signed-off-by: Shayne Chen <shayne.chen@mediatek.com>
 ---
@@ -11,7 +11,7 @@
  mt76_connac_mcu.c |    4 +
  mt76_connac_mcu.h |    2 +
  mt7915/init.c     |    2 +-
- mt7915/mac.c      |   35 +-
+ mt7915/mac.c      |   37 +-
  mt7915/main.c     |    2 +-
  mt7915/mcu.c      |   10 +-
  mt7915/mcu.h      |   28 +-
@@ -24,7 +24,7 @@
  testmode.h        |   75 +++
  tools/fields.c    |   80 ++++
  tx.c              |    3 +-
- 19 files changed, 1961 insertions(+), 146 deletions(-)
+ 19 files changed, 1962 insertions(+), 147 deletions(-)
 
 diff --git a/dma.c b/dma.c
 index 4b181305..82b4da26 100644
@@ -41,7 +41,7 @@
  #endif
  
 diff --git a/mac80211.c b/mac80211.c
-index 7ef853cb..454f449d 100644
+index e5d8f45b..4b63ec69 100644
 --- a/mac80211.c
 +++ b/mac80211.c
 @@ -55,6 +55,13 @@ static const struct ieee80211_channel mt76_channels_5ghz[] = {
@@ -71,7 +71,7 @@
  
  static const struct ieee80211_channel mt76_channels_6ghz[] = {
 diff --git a/mt76.h b/mt76.h
-index fac1dfb7..c4cdb4ba 100644
+index 3a177fff..e79d74a4 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -624,6 +624,21 @@ struct mt76_testmode_ops {
@@ -222,7 +222,7 @@
  			*hw = dev->phys[i]->hw;
  			return true;
  		}
-@@ -1226,7 +1317,8 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
+@@ -1227,7 +1318,8 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
  int mt76_testmode_dump(struct ieee80211_hw *hw, struct sk_buff *skb,
  		       struct netlink_callback *cb, void *data, int len);
  int mt76_testmode_set_state(struct mt76_phy *phy, enum mt76_testmode_state state);
@@ -233,7 +233,7 @@
  static inline void mt76_testmode_reset(struct mt76_phy *phy, bool disable)
  {
 diff --git a/mt76_connac_mcu.c b/mt76_connac_mcu.c
-index be2a2de1..01561a56 100644
+index 7ab491d6..afdd42ff 100644
 --- a/mt76_connac_mcu.c
 +++ b/mt76_connac_mcu.c
 @@ -393,6 +393,7 @@ void mt76_connac_mcu_sta_basic_tlv(struct sk_buff *skb,
@@ -255,10 +255,10 @@
  		return;
  
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 01035b28..a60965a2 100644
+index c4262f39..858a2676 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -975,6 +975,7 @@ enum {
+@@ -980,6 +980,7 @@ enum {
  	MCU_EXT_EVENT_FW_LOG_2_HOST = 0x13,
  	MCU_EXT_EVENT_THERMAL_PROTECT = 0x22,
  	MCU_EXT_EVENT_ASSERT_DUMP = 0x23,
@@ -266,7 +266,7 @@
  	MCU_EXT_EVENT_RDD_REPORT = 0x3a,
  	MCU_EXT_EVENT_CSA_NOTIFY = 0x4f,
  	MCU_EXT_EVENT_BCC_NOTIFY = 0x75,
-@@ -1153,6 +1154,7 @@ enum {
+@@ -1158,6 +1159,7 @@ enum {
  	MCU_EXT_CMD_PHY_STAT_INFO = 0xad,
  	/* for vendor csi and air monitor */
  	MCU_EXT_CMD_SMESH_CTRL = 0xae,
@@ -275,10 +275,10 @@
  	MCU_EXT_CMD_CSI_CTRL = 0xc2,
  };
 diff --git a/mt7915/init.c b/mt7915/init.c
-index d83ba2bc..6833bbf5 100644
+index 442e19e8..69465dd0 100644
 --- a/mt7915/init.c
 +++ b/mt7915/init.c
-@@ -576,7 +576,7 @@ static void mt7915_init_work(struct work_struct *work)
+@@ -600,7 +600,7 @@ static void mt7915_init_work(struct work_struct *work)
  	struct mt7915_dev *dev = container_of(work, struct mt7915_dev,
  				 init_work);
  
@@ -288,10 +288,10 @@
  	mt7915_init_txpower(dev, &dev->mphy.sband_2g.sband);
  	mt7915_init_txpower(dev, &dev->mphy.sband_5g.sband);
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index e0210c3e..100ed7e1 100644
+index d0aa305a..9af86163 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -567,16 +567,38 @@ mt7915_mac_write_txwi_tm(struct mt7915_phy *phy, __le32 *txwi,
+@@ -597,16 +597,38 @@ mt7915_mac_write_txwi_tm(struct mt7915_phy *phy, __le32 *txwi,
  {
  #ifdef CONFIG_NL80211_TESTMODE
  	struct mt76_testmode_data *td = &phy->mt76->test;
@@ -333,7 +333,7 @@
  
  	switch (td->tx_rate_mode) {
  	case MT76_TM_TX_MODE_HT:
-@@ -666,13 +688,14 @@ mt7915_mac_write_txwi_tm(struct mt7915_phy *phy, __le32 *txwi,
+@@ -696,13 +718,14 @@ mt7915_mac_write_txwi_tm(struct mt7915_phy *phy, __le32 *txwi,
  	if (mode >= MT_PHY_TYPE_HE_SU)
  		val |= FIELD_PREP(MT_TXD6_HELTF, td->tx_ltf);
  
@@ -351,11 +351,20 @@
  #endif
  }
  
+@@ -1452,7 +1475,7 @@ mt7915_mac_restart(struct mt7915_dev *dev)
+ 		goto out;
+ 
+ 	/* set the necessary init items */
+-	ret = mt7915_mcu_set_eeprom(dev);
++	ret = mt7915_mcu_set_eeprom(dev, dev->flash_mode);
+ 	if (ret)
+ 		goto out;
+ 
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 98dce0f4..0a5a4b36 100644
+index 97bf5117..b4564e33 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -224,7 +224,7 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
+@@ -223,7 +223,7 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
  	mvif->phy = phy;
  	mvif->mt76.band_idx = phy->band_idx;
  
@@ -365,10 +374,10 @@
  		mvif->mt76.wmm_idx += 2;
  
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index bcecc5e3..1b566351 100644
+index 2a18dd53..adc14d53 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -434,6 +434,11 @@ mt7915_mcu_rx_ext_event(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -363,6 +363,11 @@ mt7915_mcu_rx_ext_event(struct mt7915_dev *dev, struct sk_buff *skb)
  	case MCU_EXT_EVENT_BCC_NOTIFY:
  		mt7915_mcu_rx_bcc_notify(dev, skb);
  		break;
@@ -380,7 +389,7 @@
  	default:
  		break;
  	}
-@@ -465,6 +470,7 @@ void mt7915_mcu_rx_event(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -394,6 +399,7 @@ void mt7915_mcu_rx_event(struct mt7915_dev *dev, struct sk_buff *skb)
  	    rxd->ext_eid == MCU_EXT_EVENT_ASSERT_DUMP ||
  	    rxd->ext_eid == MCU_EXT_EVENT_PS_SYNC ||
  	    rxd->ext_eid == MCU_EXT_EVENT_BCC_NOTIFY ||
@@ -388,7 +397,7 @@
  	    !rxd->seq)
  		mt7915_mcu_rx_unsolicited_event(dev, skb);
  	else
-@@ -2826,14 +2832,14 @@ static int mt7915_mcu_set_eeprom_flash(struct mt7915_dev *dev)
+@@ -2755,14 +2761,14 @@ static int mt7915_mcu_set_eeprom_flash(struct mt7915_dev *dev)
  	return 0;
  }
  
@@ -406,7 +415,7 @@
  
  	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(EFUSE_BUFFER_MODE),
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index 0a77ad0d..ad85e56c 100644
+index 8eaf984a..1388eda0 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
 @@ -8,10 +8,15 @@
@@ -425,7 +434,7 @@
  };
  
  struct mt7915_mcu_thermal_ctrl {
-@@ -432,6 +437,12 @@ enum {
+@@ -434,6 +439,12 @@ enum {
  
  enum {
  	MT_BF_SOUNDING_ON = 1,
@@ -438,7 +447,7 @@
  	MT_BF_TYPE_UPDATE = 20,
  	MT_BF_MODULE_UPDATE = 25
  };
-@@ -665,10 +676,19 @@ struct mt7915_muru {
+@@ -668,10 +679,19 @@ struct mt7915_muru {
  #define MURU_OFDMA_SCH_TYPE_UL          BIT(1)
  
  /* Common Config */
@@ -463,10 +472,10 @@
  
  enum {
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 2e73bd79..1eda361f 100644
+index 813d6f40..63b66e40 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
-@@ -85,6 +85,7 @@ static const u32 mt7915_offs[] = {
+@@ -127,6 +127,7 @@ static const u32 mt7915_offs[] = {
  	[ARB_DRNGR0]		= 0x194,
  	[ARB_SCR]		= 0x080,
  	[RMAC_MIB_AIRTIME14]	= 0x3b8,
@@ -474,7 +483,7 @@
  	[AGG_AWSCR0]		= 0x05c,
  	[AGG_PCR0]		= 0x06c,
  	[AGG_ACR0]		= 0x084,
-@@ -160,6 +161,7 @@ static const u32 mt7916_offs[] = {
+@@ -202,6 +203,7 @@ static const u32 mt7916_offs[] = {
  	[ARB_DRNGR0]		= 0x1e0,
  	[ARB_SCR]		= 0x000,
  	[RMAC_MIB_AIRTIME14]	= 0x0398,
@@ -483,10 +492,10 @@
  	[AGG_PCR0]		= 0x040,
  	[AGG_ACR0]		= 0x054,
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 6868813a..3bfec8fa 100644
+index 6458e356..0217c6c3 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -301,6 +301,9 @@ struct mt7915_phy {
+@@ -314,6 +314,9 @@ struct mt7915_phy {
  		u8 last_snr;
  
  		u8 spe_idx;
@@ -496,7 +505,7 @@
  	} test;
  #endif
  
-@@ -392,6 +395,14 @@ struct mt7915_dev {
+@@ -413,6 +416,14 @@ struct mt7915_dev {
  	void __iomem *dcm;
  	void __iomem *sku;
  
@@ -511,7 +520,7 @@
  #ifdef MTK_DEBUG
  	u16 wlan_idx;
  	struct {
-@@ -570,7 +581,7 @@ int mt7915_mcu_set_fixed_rate_ctrl(struct mt7915_dev *dev,
+@@ -584,7 +595,7 @@ int mt7915_mcu_set_fixed_rate_ctrl(struct mt7915_dev *dev,
  				   struct ieee80211_vif *vif,
  				   struct ieee80211_sta *sta,
  				   void *data, u32 field);
@@ -520,7 +529,7 @@
  int mt7915_mcu_get_eeprom(struct mt7915_dev *dev, u32 offset);
  int mt7915_mcu_get_eeprom_free_block(struct mt7915_dev *dev, u8 *block_num);
  int mt7915_mcu_set_mac(struct mt7915_dev *dev, int band, bool enable,
-@@ -603,6 +614,7 @@ int mt7915_mcu_fw_log_2_host(struct mt7915_dev *dev, u8 type, u8 ctrl);
+@@ -617,6 +628,7 @@ int mt7915_mcu_fw_log_2_host(struct mt7915_dev *dev, u8 type, u8 ctrl);
  int mt7915_mcu_fw_dbg_ctrl(struct mt7915_dev *dev, u32 module, u8 level);
  void mt7915_mcu_rx_event(struct mt7915_dev *dev, struct sk_buff *skb);
  void mt7915_mcu_exit(struct mt7915_dev *dev);
@@ -529,10 +538,10 @@
  static inline u16 mt7915_wtbl_size(struct mt7915_dev *dev)
  {
 diff --git a/mt7915/regs.h b/mt7915/regs.h
-index 3f283a83..8fd2f69a 100644
+index 947f02f2..3bf9e150 100644
 --- a/mt7915/regs.h
 +++ b/mt7915/regs.h
-@@ -47,6 +47,7 @@ enum offs_rev {
+@@ -61,6 +61,7 @@ enum offs_rev {
  	ARB_DRNGR0,
  	ARB_SCR,
  	RMAC_MIB_AIRTIME14,
@@ -540,7 +549,7 @@
  	AGG_AWSCR0,
  	AGG_PCR0,
  	AGG_ACR0,
-@@ -464,6 +465,8 @@ enum offs_rev {
+@@ -481,6 +482,8 @@ enum offs_rev {
  #define MT_WF_AGG_BASE(_band)		((_band) ? 0x820f2000 : 0x820e2000)
  #define MT_WF_AGG(_band, ofs)		(MT_WF_AGG_BASE(_band) + (ofs))
  
@@ -2908,5 +2917,5 @@
  			wake_up(&dev->tx_wait);
  
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1112-mt76-testmode-add-pre-cal-support.patch b/recipes-wifi/linux-mt76/files/patches/1112-mt76-testmode-add-pre-cal-support.patch
index 1310b9b..bde5241 100644
--- a/recipes-wifi/linux-mt76/files/patches/1112-mt76-testmode-add-pre-cal-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1112-mt76-testmode-add-pre-cal-support.patch
@@ -1,7 +1,7 @@
-From 809cc2ea59de51435e0c33466ff2f6ab280ff043 Mon Sep 17 00:00:00 2001
+From cefbd5d7c2c8c2986ed7344e71e6d949d4744da9 Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Wed, 31 Aug 2022 20:06:52 +0800
-Subject: [PATCH 1112/1127] mt76: testmode: add pre-cal support
+Subject: [PATCH 1112/1128] mt76: testmode: add pre-cal support
 
 Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Change-Id: Ibfbbc3443de994eeb4daa5e364b0a90f5d7d3bcd
@@ -37,7 +37,7 @@
  
  out_put_node:
 diff --git a/mt76.h b/mt76.h
-index c4cdb4ba..3ca449f7 100644
+index e79d74a4..c08b8a47 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -625,6 +625,7 @@ struct mt76_testmode_ops {
@@ -49,10 +49,10 @@
  
  struct mt76_testmode_entry_data {
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index a60965a2..b14f931b 100644
+index 858a2676..c510b5d4 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -971,6 +971,7 @@ enum {
+@@ -976,6 +976,7 @@ enum {
  
  /* ext event table */
  enum {
@@ -114,10 +114,10 @@
  
  #endif
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 1b566351..34ce7d6f 100644
+index adc14d53..f4285994 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -438,6 +438,9 @@ mt7915_mcu_rx_ext_event(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -367,6 +367,9 @@ mt7915_mcu_rx_ext_event(struct mt7915_dev *dev, struct sk_buff *skb)
  	case MCU_EXT_EVENT_BF_STATUS_READ:
  		mt7915_tm_txbf_status_read(dev, skb);
  		break;
@@ -127,7 +127,7 @@
  #endif
  	default:
  		break;
-@@ -2927,7 +2930,7 @@ int mt7915_mcu_apply_group_cal(struct mt7915_dev *dev)
+@@ -2856,7 +2859,7 @@ int mt7915_mcu_apply_group_cal(struct mt7915_dev *dev)
  	u8 idx = 0, *cal = dev->cal, *eep = dev->mt76.eeprom.data;
  	u32 total = MT_EE_CAL_GROUP_SIZE;
  
@@ -136,7 +136,7 @@
  		return 0;
  
  	/*
-@@ -3007,11 +3010,29 @@ int mt7915_mcu_apply_tx_dpd(struct mt7915_phy *phy)
+@@ -2936,11 +2939,29 @@ int mt7915_mcu_apply_tx_dpd(struct mt7915_phy *phy)
  {
  	struct mt7915_dev *dev = phy->dev;
  	struct cfg80211_chan_def *chandef = &phy->mt76->chandef;
@@ -169,10 +169,10 @@
  
  	idx = mt7915_dpd_freq_idx(center_freq, chandef->width);
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 3bfec8fa..f3bbdbae 100644
+index 0217c6c3..e801fa30 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -379,6 +379,10 @@ struct mt7915_dev {
+@@ -400,6 +400,10 @@ struct mt7915_dev {
  	struct rchan *relay_fwlog;
  
  	void *cal;
@@ -183,7 +183,7 @@
  
  	struct {
  		u8 debug_wm;
-@@ -615,6 +619,7 @@ int mt7915_mcu_fw_dbg_ctrl(struct mt7915_dev *dev, u32 module, u8 level);
+@@ -629,6 +633,7 @@ int mt7915_mcu_fw_dbg_ctrl(struct mt7915_dev *dev, u32 module, u8 level);
  void mt7915_mcu_rx_event(struct mt7915_dev *dev, struct sk_buff *skb);
  void mt7915_mcu_exit(struct mt7915_dev *dev);
  int mt7915_tm_txbf_status_read(struct mt7915_dev *dev, struct sk_buff *skb);
@@ -842,5 +842,5 @@
  
  static const char * const testmode_tx_mode[] = {
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1113-mt76-testmode-add-iBF-command-mode-support.patch b/recipes-wifi/linux-mt76/files/patches/1113-mt76-testmode-add-iBF-command-mode-support.patch
index cfa19e2..7adbf9a 100644
--- a/recipes-wifi/linux-mt76/files/patches/1113-mt76-testmode-add-iBF-command-mode-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1113-mt76-testmode-add-iBF-command-mode-support.patch
@@ -1,7 +1,7 @@
-From 3c19e3a62e66bcbcc35989d5ddea6a6e38f406af Mon Sep 17 00:00:00 2001
+From 9e9c62bb30cbfb1c5d65cbe7a7a29b4ddbefcfca Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Mon, 12 Sep 2022 18:16:54 +0800
-Subject: [PATCH 1113/1127] mt76: testmode: add iBF command mode support
+Subject: [PATCH 1113/1128] mt76: testmode: add iBF command mode support
 
 Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Change-Id: I7eea1d6412563f889e5774e787e58ce9eba001bd
@@ -239,5 +239,5 @@
  
  const struct tm_field msg_field = {
 -- 
-2.25.1
+2.18.0
 
diff --git a/recipes-wifi/linux-mt76/files/patches/1114-mt76-testmode-add-ZWDFS-test-mode-support.patch b/recipes-wifi/linux-mt76/files/patches/1114-mt76-testmode-add-ZWDFS-test-mode-support.patch
index 1deda11..a06ebcd 100644
--- a/recipes-wifi/linux-mt76/files/patches/1114-mt76-testmode-add-ZWDFS-test-mode-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1114-mt76-testmode-add-ZWDFS-test-mode-support.patch
@@ -1,27 +1,28 @@
-From 8f5eeab00cf1eeb394132306db23fb1cd2ef5afa Mon Sep 17 00:00:00 2001
+From d4325a391a9e7ce10af23810f138c982e4e387ec Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Thu, 27 Oct 2022 17:42:07 +0800
-Subject: [PATCH] mt76: testmode: add ZWDFS test mode support
+Subject: [PATCH 1114/1128] mt76: testmode: add ZWDFS test mode support
 
 Change-Id: I14d104b7158a35acf6b0595357d07fb87f5a9d94
 Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
- mt76.h            |   8 ++
+ mt76.h            |   9 ++
  mt76_connac_mcu.h |   2 +
- mt7915/mcu.c      |  64 ++++++++++++++
- mt7915/mcu.h      |  46 ++++++++++
+ mt7915/mcu.c      |  66 +++++++++++++
+ mt7915/mcu.h      |  46 +++++++++
  mt7915/mt7915.h   |   4 +
- mt7915/testmode.c | 213 ++++++++++++++++++++++++++++++++++++++++++++++
- testmode.c        |  23 ++++-
- testmode.h        |  43 ++++++++++
- tools/fields.c    |  20 +++++
- 9 files changed, 422 insertions(+), 1 deletion(-)
+ mt7915/regs.h     |   2 +
+ mt7915/testmode.c | 232 ++++++++++++++++++++++++++++++++++++++++++++++
+ testmode.c        |  25 ++++-
+ testmode.h        |  45 +++++++++
+ tools/fields.c    |  22 +++++
+ 10 files changed, 452 insertions(+), 1 deletion(-)
 
 diff --git a/mt76.h b/mt76.h
-index 3ca449f..adeba98 100644
+index c08b8a47..0a9552b5 100644
 --- a/mt76.h
 +++ b/mt76.h
-@@ -708,6 +708,14 @@ struct mt76_testmode_data {
+@@ -708,6 +708,15 @@ struct mt76_testmode_data {
  		u64 fcs_error[__MT_RXQ_MAX];
  		u64 len_mismatch;
  	} rx_stats;
@@ -33,14 +34,15 @@
 +	u8 ipi_threshold;
 +	u32 ipi_period;
 +	u8 ipi_antenna_idx;
++	u8 ipi_reset;
  };
  
  struct mt76_vif {
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index b14f931..d7ea781 100644
+index c510b5d4..a31b85f0 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1148,6 +1148,7 @@ enum {
+@@ -1153,6 +1153,7 @@ enum {
  	MCU_EXT_CMD_OFFCH_SCAN_CTRL = 0x9a,
  	MCU_EXT_CMD_SET_RDD_TH = 0x9d,
  	MCU_EXT_CMD_MURU_CTRL = 0x9f,
@@ -48,7 +50,7 @@
  	MCU_EXT_CMD_RX_STAT = 0xa4,
  	MCU_EXT_CMD_SET_SPR = 0xa8,
  	MCU_EXT_CMD_GROUP_PRE_CAL_INFO = 0xab,
-@@ -1158,6 +1159,7 @@ enum {
+@@ -1163,6 +1164,7 @@ enum {
  	MCU_EXT_CMD_RX_STAT_USER_CTRL = 0xb3,
  	MCU_EXT_CMD_CERT_CFG = 0xb7,
  	MCU_EXT_CMD_CSI_CTRL = 0xc2,
@@ -57,10 +59,10 @@
  
  enum {
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 34ce7d6..87578d7 100644
+index f4285994..0e66291d 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2665,6 +2665,7 @@ mt7915_mcu_background_chain_ctrl(struct mt7915_phy *phy,
+@@ -2594,6 +2594,7 @@ mt7915_mcu_background_chain_ctrl(struct mt7915_phy *phy,
  		req.monitor_chan = chandef->chan->hw_value;
  		req.monitor_central_chan =
  			ieee80211_frequency_to_channel(chandef->center_freq1);
@@ -68,7 +70,7 @@
  		req.band_idx = phy != &dev->phy;
  		req.scan_mode = 2;
  		break;
-@@ -4236,3 +4237,66 @@ int mt7915_mcu_set_amsdu_algo(struct mt7915_dev *dev, u16 wcid, u8 enable)
+@@ -4180,3 +4181,68 @@ int mt7915_mcu_set_amsdu_algo(struct mt7915_dev *dev, u16 wcid, u8 enable)
  	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(MEC_CTRL), &req, sizeof(req), true);
  }
  #endif
@@ -92,14 +94,16 @@
 +		.band_idx = phy->band_idx,
 +	};
 +
-+	ret = mt76_mcu_send_and_get_msg(&dev->mt76, MCU_EXT_CMD(IPI_HIST_CTRL),
++	if (!wait_resp)
++		return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(IPI_HIST_CTRL),
++					 &req, sizeof(req), true);
++
++	ret = mt76_mcu_send_and_get_msg(&dev->mt76, MCU_EXT_QUERY(IPI_HIST_CTRL),
 +					&req, sizeof(req), wait_resp, &skb);
++
 +	if (ret)
 +		return ret;
 +
-+	if (!wait_resp)
-+		return 0;
-+
 +	memcpy(data, skb->data, sizeof(struct mt7915_mcu_rdd_ipi_ctrl));
 +	dev_kfree_skb(skb);
 +
@@ -136,10 +140,10 @@
 +	return 0;
 +}
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index ad85e56..e0fb5a1 100644
+index 1388eda0..0a79fe04 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -576,6 +576,52 @@ struct csi_data {
+@@ -579,6 +579,52 @@ struct csi_data {
  };
  #endif
  
@@ -193,10 +197,10 @@
  #define OFDMA_DL                       BIT(0)
  #define OFDMA_UL                       BIT(1)
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index f3bbdba..d29c8ef 100644
+index e801fa30..dcf64bff 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -289,6 +289,7 @@ struct mt7915_phy {
+@@ -302,6 +302,7 @@ struct mt7915_phy {
  
  	struct mib_stats mib;
  	struct mt76_channel_state state_ts;
@@ -204,7 +208,7 @@
  
  #ifdef CONFIG_NL80211_TESTMODE
  	struct {
-@@ -725,6 +726,9 @@ int mt7915_vendor_amnt_sta_remove(struct mt7915_phy *phy,
+@@ -746,6 +747,9 @@ int mt7915_vendor_amnt_sta_remove(struct mt7915_phy *phy,
  				  struct ieee80211_sta *sta);
  #endif
  
@@ -214,11 +218,24 @@
  #ifdef MTK_DEBUG
  int mt7915_mtk_init_debugfs(struct mt7915_phy *phy, struct dentry *dir);
  int mt7915_dbg_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a3, bool wait_resp);
+diff --git a/mt7915/regs.h b/mt7915/regs.h
+index 3bf9e150..9b6266c1 100644
+--- a/mt7915/regs.h
++++ b/mt7915/regs.h
+@@ -1180,6 +1180,8 @@ enum offs_rev {
+ #define MT_WF_IRPI_NSS(phy, nss)	MT_WF_IRPI(0x6000 + ((phy) << 20) + ((nss) << 16))
+ #define MT_WF_IRPI_NSS_MT7916(phy, nss)	MT_WF_IRPI(0x1000 + ((phy) << 20) + ((nss) << 16))
+ 
++#define MT_WF_IPI_RESET			0x831a3008
++
+ /* PHY */
+ #define MT_WF_PHY_BASE			0x83080000
+ #define MT_WF_PHY(ofs)			(MT_WF_PHY_BASE + (ofs))
 diff --git a/mt7915/testmode.c b/mt7915/testmode.c
-index f735ed6..8c48d2d 100644
+index f735ed69..b3462bcc 100644
 --- a/mt7915/testmode.c
 +++ b/mt7915/testmode.c
-@@ -13,6 +13,11 @@ enum {
+@@ -13,6 +13,12 @@ enum {
  	TM_CHANGED_AID,
  	TM_CHANGED_CFG,
  	TM_CHANGED_TXBF_ACT,
@@ -227,10 +244,11 @@
 +	TM_CHANGED_OFF_CHAN_BW,
 +	TM_CHANGED_IPI_THRESHOLD,
 +	TM_CHANGED_IPI_PERIOD,
++	TM_CHANGED_IPI_RESET,
  
  	/* must be last */
  	NUM_TM_CHANGED
-@@ -24,6 +29,11 @@ static const u8 tm_change_map[] = {
+@@ -24,6 +30,12 @@ static const u8 tm_change_map[] = {
  	[TM_CHANGED_AID] = MT76_TM_ATTR_AID,
  	[TM_CHANGED_CFG] = MT76_TM_ATTR_CFG,
  	[TM_CHANGED_TXBF_ACT] = MT76_TM_ATTR_TXBF_ACT,
@@ -239,10 +257,11 @@
 +	[TM_CHANGED_OFF_CHAN_BW] = MT76_TM_ATTR_OFF_CH_SCAN_BW,
 +	[TM_CHANGED_IPI_THRESHOLD] = MT76_TM_ATTR_IPI_THRESHOLD,
 +	[TM_CHANGED_IPI_PERIOD] = MT76_TM_ATTR_IPI_PERIOD,
++	[TM_CHANGED_IPI_RESET] = MT76_TM_ATTR_IPI_RESET,
  };
  
  struct reg_band {
-@@ -962,6 +972,201 @@ mt7915_tm_set_txbf(struct mt7915_phy *phy)
+@@ -962,6 +974,216 @@ mt7915_tm_set_txbf(struct mt7915_phy *phy)
  	return 0;
  }
  
@@ -266,7 +285,7 @@
 +		[NL80211_CHAN_WIDTH_160] = 160,
 +	};
 +
-+	if (phy->band_idx != NL80211_BAND_5GHZ && !freq) {
++	if (!mphy->cap.has_5ghz || !freq) {
 +		ret = -EINVAL;
 +		dev_info(dev->mt76.dev, "Failed to set offchan (invalid band or channel)!\n");
 +		goto out;
@@ -424,16 +443,31 @@
 +	} else {
 +		struct mt7915_mcu_rdd_ipi_ctrl data;
 +
++		start_antenna_idx = 4;
 +		mt7915_mcu_ipi_hist_ctrl(phy, &data, RDD_IPI_HIST_ALL_CNT, true);
 +		mt7915_tm_dump_ipi(phy, &data, antenna_num, start_antenna_idx, false);
 +	}
 +}
 +
++static inline void
++mt7915_tm_reset_ipi(struct mt7915_phy *phy)
++{
++#define IPI_RESET_BIT	BIT(2)
++	struct mt7915_dev *dev = phy->dev;
++
++	if (is_mt7915(&dev->mt76))
++		mt7915_mcu_ipi_hist_ctrl(phy, NULL, RDD_SET_IPI_HIST_RESET, false);
++	else
++		mt76_set(dev, MT_WF_IPI_RESET, IPI_RESET_BIT);
++}
++
 +static int
 +mt7915_tm_set_ipi(struct mt7915_phy *phy)
 +{
 +	struct mt76_testmode_data *td = &phy->mt76->test;
 +
++	mt7915_tm_reset_ipi(phy);
++
 +	cancel_delayed_work(&phy->ipi_work);
 +	ieee80211_queue_delayed_work(phy->mt76->hw, &phy->ipi_work,
 +				     msecs_to_jiffies(td->ipi_period));
@@ -444,7 +478,7 @@
  static int
  mt7915_tm_set_wmm_qid(struct mt7915_phy *phy, u8 qid, u8 aifs, u8 cw_min,
  		      u16 cw_max, u16 txop, u8 tx_cmd)
-@@ -1247,6 +1452,8 @@ mt7915_tm_init(struct mt7915_phy *phy, bool en)
+@@ -1247,6 +1469,8 @@ mt7915_tm_init(struct mt7915_phy *phy, bool en)
  		phy->mt76->test.tx_mpdu_len = 0;
  		phy->test.bf_en = 0;
  		mt7915_tm_set_entry(phy);
@@ -453,7 +487,7 @@
  	}
  }
  
-@@ -2004,6 +2211,12 @@ mt7915_tm_update_params(struct mt7915_phy *phy, u32 changed)
+@@ -2004,6 +2228,14 @@ mt7915_tm_update_params(struct mt7915_phy *phy, u32 changed)
  		mt7915_tm_set_cfg(phy);
  	if (changed & BIT(TM_CHANGED_TXBF_ACT))
  		mt7915_tm_set_txbf(phy);
@@ -463,14 +497,16 @@
 +	if ((changed & BIT(TM_CHANGED_IPI_THRESHOLD)) &&
 +	    (changed & BIT(TM_CHANGED_IPI_PERIOD)))
 +		mt7915_tm_set_ipi(phy);
++	if (changed & BIT(TM_CHANGED_IPI_RESET))
++		mt7915_tm_reset_ipi(phy);
  }
  
  static int
 diff --git a/testmode.c b/testmode.c
-index aa874a8..de2892b 100644
+index aa874a83..b19b872a 100644
 --- a/testmode.c
 +++ b/testmode.c
-@@ -24,6 +24,12 @@ const struct nla_policy mt76_tm_policy[NUM_MT76_TM_ATTRS] = {
+@@ -24,6 +24,13 @@ const struct nla_policy mt76_tm_policy[NUM_MT76_TM_ATTRS] = {
  	[MT76_TM_ATTR_TX_TIME] = { .type = NLA_U32 },
  	[MT76_TM_ATTR_FREQ_OFFSET] = { .type = NLA_U32 },
  	[MT76_TM_ATTR_DRV_DATA] = { .type = NLA_NESTED },
@@ -480,10 +516,11 @@
 +	[MT76_TM_ATTR_IPI_THRESHOLD] = { .type = NLA_U8 },
 +	[MT76_TM_ATTR_IPI_PERIOD] = { .type = NLA_U32 },
 +	[MT76_TM_ATTR_IPI_ANTENNA_INDEX] = { .type = NLA_U8 },
++	[MT76_TM_ATTR_IPI_RESET] = { .type = NLA_U8 },
  };
  EXPORT_SYMBOL_GPL(mt76_tm_policy);
  
-@@ -402,6 +408,7 @@ mt76_testmode_init_defaults(struct mt76_phy *phy)
+@@ -402,6 +409,7 @@ mt76_testmode_init_defaults(struct mt76_phy *phy)
  	td->tx_count = 1;
  	td->tx_rate_mode = MT76_TM_TX_MODE_OFDM;
  	td->tx_rate_nss = 1;
@@ -491,7 +528,7 @@
  
  	memcpy(td->addr[0], phy->macaddr, ETH_ALEN);
  	memcpy(td->addr[1], phy->macaddr, ETH_ALEN);
-@@ -607,6 +614,9 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
+@@ -607,6 +615,9 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
  	if (tb[MT76_TM_ATTR_TX_RATE_IDX])
  		td->tx_rate_idx = nla_get_u8(tb[MT76_TM_ATTR_TX_RATE_IDX]);
  
@@ -501,7 +538,7 @@
  	if (mt76_tm_get_u8(tb[MT76_TM_ATTR_TX_RATE_MODE], &td->tx_rate_mode,
  			   0, MT76_TM_TX_MODE_MAX) ||
  	    mt76_tm_get_u8(tb[MT76_TM_ATTR_TX_RATE_NSS], &td->tx_rate_nss,
-@@ -623,7 +633,15 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
+@@ -623,7 +634,16 @@ int mt76_testmode_cmd(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
  			   &td->tx_power_control, 0, 1) ||
  	    mt76_tm_get_u8(tb[MT76_TM_ATTR_AID], &td->aid, 0, 16) ||
  	    mt76_tm_get_u8(tb[MT76_TM_ATTR_RU_ALLOC], &td->ru_alloc, 0, 0xff) ||
@@ -514,11 +551,12 @@
 +			   &td->offchan_bw, NL80211_CHAN_WIDTH_20_NOHT, NL80211_CHAN_WIDTH_160) ||
 +	    mt76_tm_get_u8(tb[MT76_TM_ATTR_IPI_THRESHOLD], &td->ipi_threshold, 0, 10) ||
 +	    mt76_tm_get_u8(tb[MT76_TM_ATTR_IPI_ANTENNA_INDEX], &td->ipi_antenna_idx,
-+			   MT76_TM_IPI_ANTENNA_0, MT76_TM_IPI_ANTENNA_ALL))
++			   MT76_TM_IPI_ANTENNA_0, MT76_TM_IPI_ANTENNA_ALL) ||
++	    mt76_tm_get_u8(tb[MT76_TM_ATTR_IPI_RESET], &td->ipi_reset, 0, 1))
  		goto out;
  
  	if (tb[MT76_TM_ATTR_TX_LENGTH]) {
-@@ -857,6 +875,9 @@ int mt76_testmode_dump(struct ieee80211_hw *hw, struct sk_buff *msg,
+@@ -857,6 +877,9 @@ int mt76_testmode_dump(struct ieee80211_hw *hw, struct sk_buff *msg,
  	    nla_put_u8(msg, MT76_TM_ATTR_TX_RATE_MODE, td->tx_rate_mode) ||
  	    nla_put_u8(msg, MT76_TM_ATTR_TX_RATE_SGI, td->tx_rate_sgi) ||
  	    nla_put_u8(msg, MT76_TM_ATTR_TX_RATE_STBC, td->tx_rate_stbc) ||
@@ -529,10 +567,10 @@
  	     nla_put_u8(msg, MT76_TM_ATTR_TX_LTF, td->tx_ltf)) ||
  	    (mt76_testmode_param_present(td, MT76_TM_ATTR_TX_ANTENNA) &&
 diff --git a/testmode.h b/testmode.h
-index 5d1fe79..9f61847 100644
+index 5d1fe793..27a00953 100644
 --- a/testmode.h
 +++ b/testmode.h
-@@ -63,6 +63,19 @@
+@@ -63,6 +63,20 @@
   * 	(nested, u8 attrs)
   *
   * @MT76_TM_ATTR_CFG: config testmode rf feature (nested, see &mt76_testmode_cfg)
@@ -549,10 +587,11 @@
 + *			     the histogram of specific IPI index (u8)
 + * @MT76_TM_ATTR_IPI_ANTENNA_INDEX: config the antenna index for reading
 + *				    the histogram of specific IPI index (u8)
++ * @MT76_TM_ATTR_IPI_RESET: Reset the IPI counter
   *
   */
  enum mt76_testmode_attr {
-@@ -116,6 +129,15 @@ enum mt76_testmode_attr {
+@@ -116,6 +130,16 @@ enum mt76_testmode_attr {
  	MT76_TM_ATTR_TXBF_ACT,
  	MT76_TM_ATTR_TXBF_PARAM,
  
@@ -564,11 +603,12 @@
 +	MT76_TM_ATTR_IPI_THRESHOLD,
 +	MT76_TM_ATTR_IPI_PERIOD,
 +	MT76_TM_ATTR_IPI_ANTENNA_INDEX,
++	MT76_TM_ATTR_IPI_RESET,
 +
  	/* keep last */
  	NUM_MT76_TM_ATTRS,
  	MT76_TM_ATTR_MAX = NUM_MT76_TM_ATTRS - 1,
-@@ -292,4 +314,25 @@ enum mt76_testmode_txbf_act {
+@@ -292,4 +316,25 @@ enum mt76_testmode_txbf_act {
  	MT76_TM_TXBF_ACT_MAX = NUM_MT76_TM_TXBF_ACT - 1,
  };
  
@@ -595,7 +635,7 @@
 +
  #endif
 diff --git a/tools/fields.c b/tools/fields.c
-index 47fc69f..21f6b19 100644
+index 47fc69f9..6f07eed0 100644
 --- a/tools/fields.c
 +++ b/tools/fields.c
 @@ -46,6 +46,14 @@ static const char * const testmode_txbf_act[] = {
@@ -613,7 +653,7 @@
  static void print_enum(const struct tm_field *field, struct nlattr *attr)
  {
  	unsigned int i = nla_get_u8(attr);
-@@ -411,6 +419,12 @@ static const struct tm_field testdata_fields[NUM_MT76_TM_ATTRS] = {
+@@ -411,6 +419,13 @@ static const struct tm_field testdata_fields[NUM_MT76_TM_ATTRS] = {
  	FIELD(u8, RU_IDX, "ru_idx"),
  	FIELD_ENUM(TXBF_ACT, "txbf_act", testmode_txbf_act),
  	FIELD_ARRAY(u16_hex, TXBF_PARAM, "txbf_param"),
@@ -623,10 +663,11 @@
 +	FIELD(u8, IPI_THRESHOLD, "ipi_threshold"),
 +	FIELD(u32, IPI_PERIOD, "ipi_period"),
 +	FIELD(u8, IPI_ANTENNA_INDEX, "ipi_antenna_idx"),
++	FIELD(u8, IPI_RESET, "ipi_reset"),
  	FIELD_MAC(MAC_ADDRS, "mac_addrs"),
  	FIELD_NESTED_RO(STATS, stats, "",
  			.print_extra = print_extra_stats),
-@@ -442,6 +456,12 @@ static struct nla_policy testdata_policy[NUM_MT76_TM_ATTRS] = {
+@@ -442,6 +457,13 @@ static struct nla_policy testdata_policy[NUM_MT76_TM_ATTRS] = {
  	[MT76_TM_ATTR_RU_IDX] = { .type = NLA_U8 },
  	[MT76_TM_ATTR_STATS] = { .type = NLA_NESTED },
  	[MT76_TM_ATTR_TXBF_ACT] = { .type = NLA_U8 },
@@ -636,6 +677,7 @@
 +	[MT76_TM_ATTR_IPI_THRESHOLD] = { .type = NLA_U8 },
 +	[MT76_TM_ATTR_IPI_PERIOD] = { .type = NLA_U32 },
 +	[MT76_TM_ATTR_IPI_ANTENNA_INDEX] = { .type = NLA_U8 },
++	[MT76_TM_ATTR_IPI_RESET] = { .type = NLA_U8 },
  };
  
  const struct tm_field msg_field = {
diff --git a/recipes-wifi/linux-mt76/files/patches/1115-mt76-mt7915-init-rssi-in-WTBL-when-add-station.patch b/recipes-wifi/linux-mt76/files/patches/1115-mt76-mt7915-init-rssi-in-WTBL-when-add-station.patch
index b35db14..5143732 100644
--- a/recipes-wifi/linux-mt76/files/patches/1115-mt76-mt7915-init-rssi-in-WTBL-when-add-station.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1115-mt76-mt7915-init-rssi-in-WTBL-when-add-station.patch
@@ -1,4 +1,4 @@
-From 9796c5aecec2bc0b4be41c71818469ca8b6601b6 Mon Sep 17 00:00:00 2001
+From 2d9d53d38c1228b6daed13ab3bccd2fcbe6b6d63 Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Sun, 24 Apr 2022 10:07:00 +0800
 Subject: [PATCH 1115/1128] mt76: mt7915: init rssi in WTBL when add station
@@ -8,10 +8,10 @@
  1 file changed, 4 insertions(+)
 
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 0a5a4b3..fdbf1ee 100644
+index b4564e33..1864f241 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -666,6 +666,7 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -668,6 +668,7 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  	struct mt7915_phy *phy;
  #endif
  	int ret, idx;
@@ -19,7 +19,7 @@
  
  	idx = mt76_wcid_alloc(dev->mt76.wcid_mask, MT7915_WTBL_STA);
  	if (idx < 0)
-@@ -687,6 +688,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -691,6 +692,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  	if (ret)
  		return ret;
  
diff --git a/recipes-wifi/linux-mt76/files/patches/1116-mt76-mt7915-reduce-TWT-SP-sent-to-FW-for-cert.patch b/recipes-wifi/linux-mt76/files/patches/1116-mt76-mt7915-reduce-TWT-SP-sent-to-FW-for-cert.patch
index b30999b..4d39539 100644
--- a/recipes-wifi/linux-mt76/files/patches/1116-mt76-mt7915-reduce-TWT-SP-sent-to-FW-for-cert.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1116-mt76-mt7915-reduce-TWT-SP-sent-to-FW-for-cert.patch
@@ -1,4 +1,4 @@
-From 00d1ebebdfb0faf06ef9f771947d1466926616fe Mon Sep 17 00:00:00 2001
+From ebdd3b7cd18ab5f28072f7ff625654097737dc8c Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Thu, 4 Aug 2022 14:08:11 +0800
 Subject: [PATCH 1116/1128] mt76: mt7915: reduce TWT SP sent to FW for cert
@@ -11,10 +11,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 87578d7..caab84c 100644
+index 0e66291d..042b6c18 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -3559,7 +3559,7 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
+@@ -3503,7 +3503,7 @@ int mt7915_mcu_twt_agrt_update(struct mt7915_dev *dev,
  		.own_mac_idx = mvif->mt76.omac_idx,
  		.flowid = flow->id,
  		.peer_id = cpu_to_le16(flow->wcid),
diff --git a/recipes-wifi/linux-mt76/files/patches/1117-mt76-airtime-fairness-feature-off-in-mac80211.patch b/recipes-wifi/linux-mt76/files/patches/1117-mt76-airtime-fairness-feature-off-in-mac80211.patch
index ccf6d80..02a1d63 100644
--- a/recipes-wifi/linux-mt76/files/patches/1117-mt76-airtime-fairness-feature-off-in-mac80211.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1117-mt76-airtime-fairness-feature-off-in-mac80211.patch
@@ -1,4 +1,4 @@
-From c3922c28e124f89f9725781a4065d32207d8eed4 Mon Sep 17 00:00:00 2001
+From 5d3268e0d55b6bfaa88397d19ded51c13ebd8fac Mon Sep 17 00:00:00 2001
 From: Evelyn Tsai <evelyn.tsai@mediatek.com>
 Date: Fri, 6 May 2022 15:58:42 +0800
 Subject: [PATCH 1117/1128] mt76: airtime fairness feature off in mac80211
@@ -8,7 +8,7 @@
  1 file changed, 1 deletion(-)
 
 diff --git a/mac80211.c b/mac80211.c
-index 454f449..b7c1b13 100644
+index 4b63ec69..b378231c 100644
 --- a/mac80211.c
 +++ b/mac80211.c
 @@ -429,7 +429,6 @@ mt76_phy_init(struct mt76_phy *phy, struct ieee80211_hw *hw)
diff --git a/recipes-wifi/linux-mt76/files/patches/1118-mt76-mt7915-add-mt7986-and-mt7916-pre-calibration.patch b/recipes-wifi/linux-mt76/files/patches/1118-mt76-mt7915-add-mt7986-and-mt7916-pre-calibration.patch
index b1676a5..58fb0fd 100644
--- a/recipes-wifi/linux-mt76/files/patches/1118-mt76-mt7915-add-mt7986-and-mt7916-pre-calibration.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1118-mt76-mt7915-add-mt7986-and-mt7916-pre-calibration.patch
@@ -1,4 +1,4 @@
-From 81944a83b700b0173adce47aa961d6798cadc150 Mon Sep 17 00:00:00 2001
+From 91e341ee0145c32a0ee05feb45bb45162622e17f Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Fri, 20 May 2022 19:19:25 +0800
 Subject: [PATCH 1118/1128] mt76: mt7915: add mt7986 and mt7916 pre-calibration
@@ -15,7 +15,7 @@
  3 files changed, 62 insertions(+), 26 deletions(-)
 
 diff --git a/mt7915/eeprom.c b/mt7915/eeprom.c
-index e2482c6..d58a320 100644
+index 0bce0ce5..0f5862e3 100644
 --- a/mt7915/eeprom.c
 +++ b/mt7915/eeprom.c
 @@ -9,23 +9,22 @@ static int mt7915_eeprom_load_precal(struct mt7915_dev *dev)
@@ -50,7 +50,7 @@
  
  static int mt7915_check_eeprom(struct mt7915_dev *dev)
 diff --git a/mt7915/eeprom.h b/mt7915/eeprom.h
-index 88aaa16..fdae347 100644
+index 88aaa16a..fdae347e 100644
 --- a/mt7915/eeprom.h
 +++ b/mt7915/eeprom.h
 @@ -19,6 +19,7 @@ enum mt7915_eeprom_field {
@@ -62,10 +62,10 @@
  	MT_EE_RATE_DELTA_5G =	0x29d,
  	MT_EE_TX0_POWER_2G =	0x2fc,
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index caab84c..8edd155 100644
+index 042b6c18..e03ec9e3 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2929,7 +2929,8 @@ static int mt7915_mcu_set_pre_cal(struct mt7915_dev *dev, u8 idx,
+@@ -2858,7 +2858,8 @@ static int mt7915_mcu_set_pre_cal(struct mt7915_dev *dev, u8 idx,
  int mt7915_mcu_apply_group_cal(struct mt7915_dev *dev)
  {
  	u8 idx = 0, *cal = dev->cal, *eep = dev->mt76.eeprom.data;
@@ -75,7 +75,7 @@
  
  	if (!(eep[offs] & MT_EE_WIFI_CAL_GROUP))
  		return 0;
-@@ -2967,9 +2968,9 @@ static int mt7915_find_freq_idx(const u16 *freqs, int n_freqs, u16 cur)
+@@ -2896,9 +2897,9 @@ static int mt7915_find_freq_idx(const u16 *freqs, int n_freqs, u16 cur)
  	return -1;
  }
  
@@ -87,7 +87,7 @@
  		5180, 5200, 5220, 5240,
  		5260, 5280, 5300, 5320,
  		5500, 5520, 5540, 5560,
-@@ -2977,34 +2978,69 @@ static int mt7915_dpd_freq_idx(u16 freq, u8 bw)
+@@ -2906,34 +2907,69 @@ static int mt7915_dpd_freq_idx(u16 freq, u8 bw)
  		5660, 5680, 5700, 5745,
  		5765, 5785, 5805, 5825
  	};
@@ -167,7 +167,7 @@
  }
  
  int mt7915_mcu_apply_tx_dpd(struct mt7915_phy *phy)
-@@ -3036,24 +3072,24 @@ int mt7915_mcu_apply_tx_dpd(struct mt7915_phy *phy)
+@@ -2965,24 +3001,24 @@ int mt7915_mcu_apply_tx_dpd(struct mt7915_phy *phy)
  	if (!(eep[offs] & dpd_mask))
  		return 0;
  
diff --git a/recipes-wifi/linux-mt76/files/patches/1119-mt76-mt7915-add-phy-capability-vendor-command.patch b/recipes-wifi/linux-mt76/files/patches/1119-mt76-mt7915-add-phy-capability-vendor-command.patch
index e634a9f..f2e7a99 100644
--- a/recipes-wifi/linux-mt76/files/patches/1119-mt76-mt7915-add-phy-capability-vendor-command.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1119-mt76-mt7915-add-phy-capability-vendor-command.patch
@@ -1,4 +1,4 @@
-From 680d744245598f99e718d68f72727e71eaeb1b72 Mon Sep 17 00:00:00 2001
+From 75cc0d6bfdbb54291917044fb0c778d2729758f6 Mon Sep 17 00:00:00 2001
 From: Yi-Chia Hsieh <Yi-Chia.Hsieh@mediatek.com>
 Date: Tue, 12 Jul 2022 10:04:35 -0700
 Subject: [PATCH 1119/1128] mt76: mt7915: add phy capability vendor command
@@ -10,7 +10,7 @@
  3 files changed, 78 insertions(+)
 
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index d29c8ef..b440a34 100644
+index dcf64bff..5023cfcb 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
 @@ -11,6 +11,7 @@
@@ -22,7 +22,7 @@
  #define MT7916_WTBL_SIZE		544
  #define MT7915_WTBL_RESERVED		(mt7915_wtbl_size(dev) - 1)
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index c755184..77d71e4 100644
+index c7551848..77d71e48 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -50,6 +50,18 @@ rfeature_ctrl_policy[NUM_MTK_VENDOR_ATTRS_RFEATURE_CTRL] = {
@@ -99,7 +99,7 @@
  };
  
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index a8e4ebf..719b851 100644
+index a8e4ebf9..719b851f 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -9,6 +9,7 @@ enum mtk_nl80211_vendor_subcmds {
diff --git a/recipes-wifi/linux-mt76/files/patches/1120-mt76-mt7915-add-vendor-subcmd-EDCCA-ctrl.patch b/recipes-wifi/linux-mt76/files/patches/1120-mt76-mt7915-add-vendor-subcmd-EDCCA-ctrl.patch
index 7f79958..97002bb 100644
--- a/recipes-wifi/linux-mt76/files/patches/1120-mt76-mt7915-add-vendor-subcmd-EDCCA-ctrl.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1120-mt76-mt7915-add-vendor-subcmd-EDCCA-ctrl.patch
@@ -1,4 +1,4 @@
-From 50c497714418693f8e2c4e8d90f4f86dbb41aa44 Mon Sep 17 00:00:00 2001
+From b3325580c9d1f3503582323e0787de7f28d49b58 Mon Sep 17 00:00:00 2001
 From: Howard Hsu <howard-yh.hsu@mediatek.com>
 Date: Fri, 24 Jun 2022 11:15:45 +0800
 Subject: [PATCH 1120/1128] mt76: mt7915: add vendor subcmd EDCCA ctrl
@@ -15,10 +15,10 @@
  7 files changed, 139 insertions(+)
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index d7ea781..1738773 100644
+index a31b85f0..bceb6799 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1158,6 +1158,7 @@ enum {
+@@ -1163,6 +1163,7 @@ enum {
  	MCU_EXT_CMD_SMESH_CTRL = 0xae,
  	MCU_EXT_CMD_RX_STAT_USER_CTRL = 0xb3,
  	MCU_EXT_CMD_CERT_CFG = 0xb7,
@@ -27,10 +27,10 @@
  	MCU_EXT_CMD_IPI_HIST_SCAN = 0xc5,
  };
 diff --git a/mt7915/main.c b/mt7915/main.c
-index fdbf1ee..80f4d9d 100644
+index 1864f241..2b4e122b 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -456,6 +456,9 @@ static int mt7915_config(struct ieee80211_hw *hw, u32 changed)
+@@ -455,6 +455,9 @@ static int mt7915_config(struct ieee80211_hw *hw, u32 changed)
  			mutex_unlock(&dev->mt76.mutex);
  		}
  #endif
@@ -41,10 +41,10 @@
  		ret = mt7915_set_channel(phy);
  		if (ret)
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 8edd155..2c2575e 100644
+index e03ec9e3..8fc40c5a 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -4336,3 +4336,41 @@ int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool w
+@@ -4282,3 +4282,41 @@ int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool w
  
  	return 0;
  }
@@ -87,10 +87,10 @@
 +	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(EDCCA), &req, sizeof(req), true);
 +}
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index 14cb04b..481ef4d 100644
+index 0a79fe04..2ca2c005 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -834,4 +834,17 @@ enum {
+@@ -836,6 +836,19 @@ enum {
     MURU_DL_INIT,
     MURU_UL_INIT,
  };
@@ -108,11 +108,13 @@
 +   EDCCA_MODE_AUTO,
 +};
  #endif
+ 
+ #endif
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index b440a34..53773fa 100644
+index 5023cfcb..1cfa6f03 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -726,6 +726,8 @@ void mt7915_vendor_amnt_fill_rx(struct mt7915_phy *phy, struct sk_buff *skb);
+@@ -747,6 +747,8 @@ void mt7915_vendor_amnt_fill_rx(struct mt7915_phy *phy, struct sk_buff *skb);
  int mt7915_vendor_amnt_sta_remove(struct mt7915_phy *phy,
  				  struct ieee80211_sta *sta);
  #endif
@@ -122,7 +124,7 @@
  int mt7915_mcu_ipi_hist_ctrl(struct mt7915_phy *phy, void *data, u8 cmd, bool wait_resp);
  int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool wait_resp);
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index 77d71e4..5a28a55 100644
+index 77d71e48..5a28a554 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -62,6 +62,17 @@ phy_capa_dump_policy[NUM_MTK_VENDOR_ATTRS_PHY_CAPA_DUMP] = {
@@ -210,7 +212,7 @@
  };
  
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index 719b851..83c41bc 100644
+index 719b851f..83c41bc1 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -10,8 +10,27 @@ enum mtk_nl80211_vendor_subcmds {
diff --git a/recipes-wifi/linux-mt76/files/patches/1121-mt76-mt7915-implement-bin-file-mode.patch b/recipes-wifi/linux-mt76/files/patches/1121-mt76-mt7915-implement-bin-file-mode.patch
index d5e605d..def5acf 100644
--- a/recipes-wifi/linux-mt76/files/patches/1121-mt76-mt7915-implement-bin-file-mode.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1121-mt76-mt7915-implement-bin-file-mode.patch
@@ -1,4 +1,4 @@
-From d4a8fb73f0ac7ca27986d91c12bfb624770474ab Mon Sep 17 00:00:00 2001
+From b42c0050ce6061473569362d2884ffabae54e404 Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Thu, 7 Jul 2022 11:09:59 +0800
 Subject: [PATCH 1121/1128] mt76: mt7915: implement bin file mode
@@ -13,7 +13,7 @@
  4 files changed, 71 insertions(+), 11 deletions(-)
 
 diff --git a/eeprom.c b/eeprom.c
-index e083964..5b9faf7 100644
+index 4c50bfe6..baca86fd 100644
 --- a/eeprom.c
 +++ b/eeprom.c
 @@ -104,6 +104,24 @@ out_put_node:
@@ -42,10 +42,10 @@
  mt76_eeprom_override(struct mt76_phy *phy)
  {
 diff --git a/mt76.h b/mt76.h
-index adeba98..93a81da 100644
+index 0a9552b5..e29f490e 100644
 --- a/mt76.h
 +++ b/mt76.h
-@@ -1009,6 +1009,7 @@ void mt76_seq_puts_array(struct seq_file *file, const char *str,
+@@ -1010,6 +1010,7 @@ void mt76_seq_puts_array(struct seq_file *file, const char *str,
  int mt76_eeprom_init(struct mt76_dev *dev, int len);
  void mt76_eeprom_override(struct mt76_phy *phy);
  int mt76_get_of_eeprom(struct mt76_dev *dev, void *data, int offset, int len);
@@ -54,7 +54,7 @@
  struct mt76_queue *
  mt76_init_queue(struct mt76_dev *dev, int qid, int idx, int n_desc,
 diff --git a/mt7915/eeprom.c b/mt7915/eeprom.c
-index d58a320..632ecc7 100644
+index 0f5862e3..0ae8d1b4 100644
 --- a/mt7915/eeprom.c
 +++ b/mt7915/eeprom.c
 @@ -46,26 +46,36 @@ static char *mt7915_eeprom_name(struct mt7915_dev *dev)
@@ -114,7 +114,7 @@
  		ret = -EINVAL;
  		goto out;
  	}
-@@ -221,12 +234,30 @@ int mt7915_eeprom_init(struct mt7915_dev *dev)
+@@ -224,12 +237,30 @@ int mt7915_eeprom_init(struct mt7915_dev *dev)
  {
  	int ret;
  
@@ -148,7 +148,7 @@
  		if (ret)
  			return ret;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 53773fa..e90fd85 100644
+index 1cfa6f03..15db02c4 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
 @@ -51,6 +51,15 @@
@@ -167,7 +167,7 @@
  #define MT7915_EEPROM_SIZE		3584
  #define MT7916_EEPROM_SIZE		4096
  
-@@ -374,6 +383,7 @@ struct mt7915_dev {
+@@ -395,6 +404,7 @@ struct mt7915_dev {
  
  	bool dbdc_support;
  	bool flash_mode;
diff --git a/recipes-wifi/linux-mt76/files/patches/1122-mt76-mt7915-initialize-wcid.patch b/recipes-wifi/linux-mt76/files/patches/1122-mt76-mt7915-initialize-wcid.patch
index 6e4a407..a71c142 100644
--- a/recipes-wifi/linux-mt76/files/patches/1122-mt76-mt7915-initialize-wcid.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1122-mt76-mt7915-initialize-wcid.patch
@@ -1,4 +1,4 @@
-From 109de0e4b5c9ed13308510e5735475cd02ea5310 Mon Sep 17 00:00:00 2001
+From 60c9370658471d7e5813edd312fa4ad1cb15e613 Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Tue, 12 Jul 2022 13:56:07 +0800
 Subject: [PATCH 1122/1128] mt76 mt7915 initialize wcid
@@ -9,10 +9,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 100ed7e..27f9419 100644
+index 9af86163..acc9871b 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -969,7 +969,7 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
+@@ -999,7 +999,7 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
  		info = le32_to_cpu(*cur_info);
  		if (info & MT_TX_FREE_PAIR) {
  			struct mt7915_sta *msta;
diff --git a/recipes-wifi/linux-mt76/files/patches/1123-mt76-HEMU-Add-dump-support.patch b/recipes-wifi/linux-mt76/files/patches/1123-mt76-HEMU-Add-dump-support.patch
index 9e08c34..1be72f3 100644
--- a/recipes-wifi/linux-mt76/files/patches/1123-mt76-HEMU-Add-dump-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1123-mt76-HEMU-Add-dump-support.patch
@@ -1,4 +1,4 @@
-From 26b122531211e0ed0d9e0daef554eaf0eb0c74a7 Mon Sep 17 00:00:00 2001
+From f57bad3523d617ebb4b1357e9e1bf28c23421fde Mon Sep 17 00:00:00 2001
 From: TomLiu <tomml.liu@mediatek.com>
 Date: Thu, 11 Aug 2022 18:09:45 -0700
 Subject: [PATCH 1123/1128] mt76: HEMU: Add dump support
@@ -10,7 +10,7 @@
  2 files changed, 27 insertions(+)
 
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index 5a28a55..7acb330 100644
+index 5a28a554..7acb3304 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -37,6 +37,7 @@ wireless_ctrl_policy[NUM_MTK_VENDOR_ATTRS_WIRELESS_CTRL] = {
@@ -61,7 +61,7 @@
  		.maxattr = MTK_VENDOR_ATTR_HEMU_CTRL_MAX,
  	},
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index 83c41bc..57f52f3 100644
+index 83c41bc1..57f52f3a 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -58,6 +58,7 @@ enum mtk_vendor_attr_hemu_ctrl {
diff --git a/recipes-wifi/linux-mt76/files/patches/1124-mt76-mt7915-add-vendor-subcmd-three-wire-PTA-ctrl.patch b/recipes-wifi/linux-mt76/files/patches/1124-mt76-mt7915-add-vendor-subcmd-three-wire-PTA-ctrl.patch
index d07dee3..a7811a0 100644
--- a/recipes-wifi/linux-mt76/files/patches/1124-mt76-mt7915-add-vendor-subcmd-three-wire-PTA-ctrl.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1124-mt76-mt7915-add-vendor-subcmd-three-wire-PTA-ctrl.patch
@@ -1,4 +1,4 @@
-From dad54bcc966435cea908f5b2fa25addd4bc25f83 Mon Sep 17 00:00:00 2001
+From 6d6786706421d191e6320d4476024dcf4a2a6e27 Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Fri, 28 Oct 2022 10:15:56 +0800
 Subject: [PATCH 1124/1128] mt76: mt7915: add vendor subcmd three wire (PTA)
@@ -16,10 +16,10 @@
  6 files changed, 107 insertions(+), 29 deletions(-)
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 1738773..9a57505 100644
+index bceb6799..86a8688e 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1157,7 +1157,7 @@ enum {
+@@ -1162,7 +1162,7 @@ enum {
  	/* for vendor csi and air monitor */
  	MCU_EXT_CMD_SMESH_CTRL = 0xae,
  	MCU_EXT_CMD_RX_STAT_USER_CTRL = 0xb3,
@@ -29,10 +29,10 @@
  	MCU_EXT_CMD_CSI_CTRL = 0xc2,
  	MCU_EXT_CMD_IPI_HIST_SCAN = 0xc5,
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 2c2575e..d59f568 100644
+index 8fc40c5a..39c8e2c2 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -4020,37 +4020,33 @@ void mt7915_mcu_set_dynalgo(struct mt7915_phy *phy, u8 enable)
+@@ -3964,37 +3964,33 @@ void mt7915_mcu_set_dynalgo(struct mt7915_phy *phy, u8 enable)
  			&req, sizeof(req), false);
  }
  
@@ -94,10 +94,10 @@
  
  void mt7915_mcu_set_bypass_smthint(struct mt7915_phy *phy, u8 val)
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index 1d58e8b..7738e96 100644
+index 2ca2c005..b2e4032f 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -622,6 +622,35 @@ struct mt7915_mcu_rdd_ipi_scan {
+@@ -625,6 +625,35 @@ struct mt7915_mcu_rdd_ipi_scan {
  	u8 tx_assert_time;						/* unit: us */
  } __packed;
  
@@ -134,10 +134,10 @@
  #define OFDMA_DL                       BIT(0)
  #define OFDMA_UL                       BIT(1)
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index e90fd85..429824b 100644
+index 15db02c4..7c7c4882 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -728,6 +728,7 @@ void mt7915_mcu_set_mimo(struct mt7915_phy *phy, u8 direction);
+@@ -749,6 +749,7 @@ void mt7915_mcu_set_mimo(struct mt7915_phy *phy, u8 direction);
  void mt7915_mcu_set_dynalgo(struct mt7915_phy *phy, u8 enable);
  int mt7915_mcu_set_mu_edca(struct mt7915_phy *phy, u8 val);
  void mt7915_mcu_set_cert(struct mt7915_phy *phy, u8 type);
@@ -146,7 +146,7 @@
  void mt7915_vendor_register(struct mt7915_phy *phy);
  int mt7915_mcu_set_csi(struct mt7915_phy *phy, u8 mode,
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index 7acb330..7f67c0d 100644
+index 7acb3304..7f67c0d3 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -40,6 +40,11 @@ hemu_ctrl_policy[NUM_MTK_VENDOR_ATTRS_HEMU_CTRL] = {
@@ -220,7 +220,7 @@
  };
  
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index 57f52f3..e0c5fd9 100644
+index 57f52f3a..e0c5fd94 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -11,6 +11,7 @@ enum mtk_nl80211_vendor_subcmds {
diff --git a/recipes-wifi/linux-mt76/files/patches/1125-mt76-add-ibf-control-vendor-cmd.patch b/recipes-wifi/linux-mt76/files/patches/1125-mt76-add-ibf-control-vendor-cmd.patch
index 0636928..0045198 100644
--- a/recipes-wifi/linux-mt76/files/patches/1125-mt76-add-ibf-control-vendor-cmd.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1125-mt76-add-ibf-control-vendor-cmd.patch
@@ -1,4 +1,4 @@
-From c3c725d511749dc69151d300906b05515521e4be Mon Sep 17 00:00:00 2001
+From d8381a4d6847fcfeb96bbfd0fbb6bcbfd9a4bd61 Mon Sep 17 00:00:00 2001
 From: mtk27835 <shurong.wen@mediatek.com>
 Date: Wed, 7 Sep 2022 14:01:29 -0700
 Subject: [PATCH 1125/1128] mt76: add ibf control vendor cmd
@@ -10,7 +10,7 @@
  2 files changed, 94 insertions(+), 1 deletion(-)
 
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index 7f67c0d..cbbb084 100644
+index 7f67c0d3..cbbb0843 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -78,6 +78,16 @@ edcca_ctrl_policy[NUM_MTK_VENDOR_ATTRS_EDCCA_CTRL] = {
@@ -105,7 +105,7 @@
  };
  
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index e0c5fd9..5aac559 100644
+index e0c5fd94..5aac5595 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -11,7 +11,8 @@ enum mtk_nl80211_vendor_subcmds {
diff --git a/recipes-wifi/linux-mt76/files/patches/1126-mt76-mt7915-add-AMPDU-AMSDU-OnOff-ctonrol.patch b/recipes-wifi/linux-mt76/files/patches/1126-mt76-mt7915-add-AMPDU-AMSDU-OnOff-ctonrol.patch
index 3c6e3ed..e9f90e1 100644
--- a/recipes-wifi/linux-mt76/files/patches/1126-mt76-mt7915-add-AMPDU-AMSDU-OnOff-ctonrol.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1126-mt76-mt7915-add-AMPDU-AMSDU-OnOff-ctonrol.patch
@@ -1,4 +1,4 @@
-From 4d425d098a578b80535153feec322a6974f88bb6 Mon Sep 17 00:00:00 2001
+From e5184f1fcbbeba3543d267190e886b1fb68cc757 Mon Sep 17 00:00:00 2001
 From: TomLiu <tomml.liu@mediatek.com>
 Date: Wed, 21 Sep 2022 13:55:15 -0700
 Subject: [PATCH 1126/1128] mt76: mt7915: add AMPDU/AMSDU OnOff ctonrol
@@ -12,10 +12,10 @@
  4 files changed, 83 insertions(+)
 
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 27f9419..3896c3d 100644
+index acc9871b..5a809c2c 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -1939,6 +1939,34 @@ static void mt7915_mac_severe_check(struct mt7915_phy *phy)
+@@ -2020,6 +2020,34 @@ static void mt7915_mac_severe_check(struct mt7915_phy *phy)
  	phy->trb_ts = trb;
  }
  
@@ -51,10 +51,10 @@
  void mt7915_capi_sta_rc_work(void *data, struct ieee80211_sta *sta)
  {
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 429824b..6e8148f 100644
+index 7c7c4882..c43661f5 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -716,6 +716,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -737,6 +737,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  			 bool pci, int *irq);
  
  #ifdef CONFIG_MTK_VENDOR
@@ -64,7 +64,7 @@
  void mt7915_set_wireless_vif(void *data, u8 *mac, struct ieee80211_vif *vif);
  void mt7915_mcu_set_rfeature_starec(void *data, struct mt7915_dev *dev,
 diff --git a/mt7915/vendor.c b/mt7915/vendor.c
-index cbbb084..d73fdd4 100644
+index cbbb0843..d73fdd4c 100644
 --- a/mt7915/vendor.c
 +++ b/mt7915/vendor.c
 @@ -30,10 +30,18 @@ wireless_ctrl_policy[NUM_MTK_VENDOR_ATTRS_WIRELESS_CTRL] = {
@@ -137,7 +137,7 @@
  		.maxattr = MTK_VENDOR_ATTR_WIRELESS_CTRL_MAX,
  	},
 diff --git a/mt7915/vendor.h b/mt7915/vendor.h
-index 5aac559..53abb10 100644
+index 5aac5595..53abb100 100644
 --- a/mt7915/vendor.h
 +++ b/mt7915/vendor.h
 @@ -58,6 +58,8 @@ enum mtk_vendor_attr_wireless_ctrl {
diff --git a/recipes-wifi/linux-mt76/files/patches/1127-mt76-mt7915-add-E3-re-bonding-for-low-yield-rate-iss.patch b/recipes-wifi/linux-mt76/files/patches/1127-mt76-mt7915-add-E3-re-bonding-for-low-yield-rate-iss.patch
index 2fb2cb1..5dd02c4 100644
--- a/recipes-wifi/linux-mt76/files/patches/1127-mt76-mt7915-add-E3-re-bonding-for-low-yield-rate-iss.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1127-mt76-mt7915-add-E3-re-bonding-for-low-yield-rate-iss.patch
@@ -1,4 +1,4 @@
-From f481a0d8fb712e0551d15d0063b3edc294238d23 Mon Sep 17 00:00:00 2001
+From d3bae8d8ba808b52ee9090e7e2a09e3750ab8465 Mon Sep 17 00:00:00 2001
 From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 Date: Thu, 13 Oct 2022 13:22:05 +0800
 Subject: [PATCH 1127/1128] mt76: mt7915: add E3 re-bonding for low yield rate
@@ -12,7 +12,7 @@
  3 files changed, 38 insertions(+), 5 deletions(-)
 
 diff --git a/mt7915/eeprom.c b/mt7915/eeprom.c
-index 632ecc7..34a4a62 100644
+index 0ae8d1b4..0c3e43b0 100644
 --- a/mt7915/eeprom.c
 +++ b/mt7915/eeprom.c
 @@ -133,7 +133,7 @@ static int mt7915_eeprom_load(struct mt7915_dev *dev)
@@ -24,7 +24,7 @@
  	}
  
  	return mt7915_check_eeprom(dev);
-@@ -230,6 +230,29 @@ void mt7915_eeprom_parse_hw_cap(struct mt7915_dev *dev,
+@@ -233,6 +233,29 @@ void mt7915_eeprom_parse_hw_cap(struct mt7915_dev *dev,
  	dev->chainshift = hweight8(dev->mphy.chainmask);
  }
  
@@ -54,7 +54,7 @@
  int mt7915_eeprom_init(struct mt7915_dev *dev)
  {
  	int ret;
-@@ -263,6 +286,8 @@ int mt7915_eeprom_init(struct mt7915_dev *dev)
+@@ -266,6 +289,8 @@ int mt7915_eeprom_init(struct mt7915_dev *dev)
  			return ret;
  	}
  
@@ -64,10 +64,10 @@
  	if (ret)
  		return ret;
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index d59f568..d50482d 100644
+index 39c8e2c2..fad35595 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2850,7 +2850,7 @@ int mt7915_mcu_set_eeprom(struct mt7915_dev *dev, bool flash_mode)
+@@ -2779,7 +2779,7 @@ int mt7915_mcu_set_eeprom(struct mt7915_dev *dev, bool flash_mode)
  				 &req, sizeof(req), true);
  }
  
@@ -76,7 +76,7 @@
  {
  	struct mt7915_mcu_eeprom_info req = {
  		.addr = cpu_to_le32(round_down(offset,
-@@ -2867,8 +2867,15 @@ int mt7915_mcu_get_eeprom(struct mt7915_dev *dev, u32 offset)
+@@ -2796,8 +2796,15 @@ int mt7915_mcu_get_eeprom(struct mt7915_dev *dev, u32 offset)
  		return ret;
  
  	res = (struct mt7915_mcu_eeprom_info *)skb->data;
@@ -95,10 +95,10 @@
  
  	return 0;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 6e8148f..c8e9c3b 100644
+index c43661f5..527ec9ea 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -544,6 +544,7 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
+@@ -559,6 +559,7 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
  
  int mt7915_register_device(struct mt7915_dev *dev);
  void mt7915_unregister_device(struct mt7915_dev *dev);
@@ -106,7 +106,7 @@
  int mt7915_eeprom_init(struct mt7915_dev *dev);
  void mt7915_eeprom_parse_hw_cap(struct mt7915_dev *dev,
  				struct mt7915_phy *phy);
-@@ -598,7 +599,7 @@ int mt7915_mcu_set_fixed_rate_ctrl(struct mt7915_dev *dev,
+@@ -612,7 +613,7 @@ int mt7915_mcu_set_fixed_rate_ctrl(struct mt7915_dev *dev,
  				   struct ieee80211_sta *sta,
  				   void *data, u32 field);
  int mt7915_mcu_set_eeprom(struct mt7915_dev *dev, bool flash_mode);
diff --git a/recipes-wifi/linux-mt76/files/patches/1128-mt76-support-on-off-SW-ACI-through-debugfs.patch b/recipes-wifi/linux-mt76/files/patches/1128-mt76-support-on-off-SW-ACI-through-debugfs.patch
index 4536ed1..208e243 100644
--- a/recipes-wifi/linux-mt76/files/patches/1128-mt76-support-on-off-SW-ACI-through-debugfs.patch
+++ b/recipes-wifi/linux-mt76/files/patches/1128-mt76-support-on-off-SW-ACI-through-debugfs.patch
@@ -1,4 +1,4 @@
-From a6c223bb69c974e93d1c3793615d1e1937d159bf Mon Sep 17 00:00:00 2001
+From adc0119417e143af9b9775a9fa4590101070fb5b Mon Sep 17 00:00:00 2001
 From: Evelyn Tsai <evelyn.tsai@mediatek.com>
 Date: Fri, 14 Oct 2022 11:15:13 +0800
 Subject: [PATCH 1128/1128] mt76: support on off SW ACI through debugfs
@@ -11,10 +11,10 @@
  2 files changed, 22 insertions(+)
 
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index 9a57505..85bf978 100644
+index 86a8688e..a368b65b 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1159,6 +1159,7 @@ enum {
+@@ -1164,6 +1164,7 @@ enum {
  	MCU_EXT_CMD_RX_STAT_USER_CTRL = 0xb3,
  	MCU_EXT_CMD_SET_CFG = 0xb7,
  	MCU_EXT_CMD_EDCCA = 0xba,
@@ -23,7 +23,7 @@
  	MCU_EXT_CMD_IPI_HIST_SCAN = 0xc5,
  };
 diff --git a/mt7915/mtk_debugfs.c b/mt7915/mtk_debugfs.c
-index 9de5b0f..c5e0472 100644
+index 9de5b0f6..c5e04728 100644
 --- a/mt7915/mtk_debugfs.c
 +++ b/mt7915/mtk_debugfs.c
 @@ -2893,6 +2893,25 @@ mt7915_wa_debug(void *data, u64 val)
diff --git a/recipes-wifi/linux-mt76/files/patches/3001-mt76-add-wed-tx-support.patch b/recipes-wifi/linux-mt76/files/patches/3001-mt76-add-wed-tx-support.patch
index f770ee0..d12e62f 100644
--- a/recipes-wifi/linux-mt76/files/patches/3001-mt76-add-wed-tx-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3001-mt76-add-wed-tx-support.patch
@@ -1,10 +1,9 @@
-From da55b34ff3c8b76a2b8d89467a95d026bdb7f015 Mon Sep 17 00:00:00 2001
+From 3eac6f7492dee323a01408cacaa85e7bc55ea1d0 Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Sun, 12 Jun 2022 16:38:45 +0800
-Subject: [PATCH 3001/3010] mt76 add wed tx support
+Subject: [PATCH 3001/3011] mt76 add wed tx support
 
 Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mt76_connac.h |  1 +
  mt7915/mac.c  | 11 +++++++----
@@ -13,7 +12,7 @@
  4 files changed, 20 insertions(+), 8 deletions(-)
 
 diff --git a/mt76_connac.h b/mt76_connac.h
-index 0915eb5..9a46887 100644
+index 0915eb57..9a468878 100644
 --- a/mt76_connac.h
 +++ b/mt76_connac.h
 @@ -116,6 +116,7 @@ struct mt76_connac_sta_key_conf {
@@ -25,10 +24,10 @@
  struct mt76_connac_fw_txp {
  	__le16 flags;
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 3896c3d..98925ed 100644
+index 5a809c2c..20e5b705 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -828,9 +828,9 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id)
+@@ -858,9 +858,9 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id)
  
  	txp->token = cpu_to_le16(token_id);
  	txp->nbuf = 1;
@@ -40,7 +39,7 @@
  }
  
  static void
-@@ -946,6 +946,7 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
+@@ -976,6 +976,7 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
  	LIST_HEAD(free_list);
  	void *end = data + len;
  	bool v3, wake = false;
@@ -48,7 +47,7 @@
  	u16 total, count = 0;
  	u32 txd = le32_to_cpu(free->txd);
  	__le32 *cur_info;
-@@ -1001,12 +1002,14 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
+@@ -1031,12 +1032,14 @@ mt7915_mac_tx_free(struct mt7915_dev *dev, void *data, int len)
  			txwi = mt76_token_release(mdev, msdu, &wake);
  			if (!txwi)
  				continue;
@@ -66,10 +65,10 @@
  
  static void
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 80f4d9d..4e91527 100644
+index 2b4e122b..f9b2c1ef 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -1457,14 +1457,14 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
+@@ -1466,14 +1466,14 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
  	if (!mtk_wed_device_active(wed))
  		return -ENODEV;
  
@@ -87,7 +86,7 @@
  
  	ctx->dev = NULL;
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 1eda361..5819281 100644
+index 63b66e40..f76f8967 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
 @@ -10,7 +10,7 @@
@@ -99,7 +98,7 @@
  module_param(wed_enable, bool, 0644);
  
  static const u32 mt7915_reg[] = {
-@@ -525,7 +525,7 @@ static void mt7915_mmio_wed_offload_disable(struct mtk_wed_device *wed)
+@@ -575,7 +575,7 @@ static void mt7915_mmio_wed_offload_disable(struct mtk_wed_device *wed)
  	dev = container_of(wed, struct mt7915_dev, mt76.mmio.wed);
  
  	spin_lock_bh(&dev->mt76.token_lock);
@@ -108,7 +107,7 @@
  	spin_unlock_bh(&dev->mt76.token_lock);
  
  	/* MT_TXD5_TX_STATUS_HOST (MPDU format) has higher priority than
-@@ -556,6 +556,9 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -606,6 +606,9 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  
  		wed->wlan.pci_dev = pci_dev;
  		wed->wlan.bus_type = MTK_WED_BUS_PCIE;
@@ -118,7 +117,7 @@
  		wed->wlan.wpdma_int = pci_resource_start(pci_dev, 0) +
  				      MT_INT_WED_SOURCE_CSR;
  		wed->wlan.wpdma_mask = pci_resource_start(pci_dev, 0) +
-@@ -566,6 +569,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -616,6 +619,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  				     MT_TXQ_WED_RING_BASE;
  		wed->wlan.wpdma_txfree = pci_resource_start(pci_dev, 0) +
  					 MT_RXQ_WED_RING_BASE;
@@ -126,7 +125,7 @@
  	} else {
  		struct platform_device *plat_dev = pdev_ptr;
  		struct resource *res;
-@@ -576,10 +580,13 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -626,10 +630,13 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  
  		wed->wlan.platform_dev = plat_dev;
  		wed->wlan.bus_type = MTK_WED_BUS_AXI;
@@ -140,7 +139,7 @@
  	}
  	wed->wlan.nbuf = 4096;
  	wed->wlan.tx_tbit[0] = is_mt7915(&dev->mt76) ? 4 : 30;
-@@ -595,6 +602,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -645,6 +652,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  
  	*irq = wed->irq;
  	dev->mt76.dma_dev = wed->dev;
diff --git a/recipes-wifi/linux-mt76/files/patches/3002-mt76-mt7915-add-wed-tx-wds-support-on-mt7986.patch b/recipes-wifi/linux-mt76/files/patches/3002-mt76-mt7915-add-wed-tx-wds-support-on-mt7986.patch
index 8f6f8e0..8132783 100644
--- a/recipes-wifi/linux-mt76/files/patches/3002-mt76-mt7915-add-wed-tx-wds-support-on-mt7986.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3002-mt76-mt7915-add-wed-tx-wds-support-on-mt7986.patch
@@ -1,10 +1,9 @@
-From 2e853a721466623df8fe208778afb48e7382b753 Mon Sep 17 00:00:00 2001
+From 2f1191e48c32e21c71c78f25961bc54baf579656 Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Sat, 10 Sep 2022 17:09:21 +0800
-Subject: [PATCH 3002/3010] mt76: mt7915: add-wed-tx-wds-support-on-mt7986
+Subject: [PATCH 3002/3011] mt76: mt7915: add-wed-tx-wds-support-on-mt7986
 
 Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mac80211.c      |  5 ++++-
  mt76.h          |  2 ++
@@ -17,10 +16,10 @@
  8 files changed, 76 insertions(+), 5 deletions(-)
 
 diff --git a/mac80211.c b/mac80211.c
-index b7c1b13..1e13b65 100644
+index b378231c..c84c9ef0 100644
 --- a/mac80211.c
 +++ b/mac80211.c
-@@ -1364,7 +1364,10 @@ void __mt76_sta_remove(struct mt76_dev *dev, struct ieee80211_vif *vif,
+@@ -1363,7 +1363,10 @@ void __mt76_sta_remove(struct mt76_dev *dev, struct ieee80211_vif *vif,
  
  	mt76_packet_id_flush(dev, wcid);
  
@@ -33,7 +32,7 @@
  }
  EXPORT_SYMBOL_GPL(__mt76_sta_remove);
 diff --git a/mt76.h b/mt76.h
-index 93a81da..1888706 100644
+index e29f490e..b86c8355 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -454,6 +454,7 @@ struct mt76_driver_ops {
@@ -44,7 +43,7 @@
  };
  
  struct mt76_channel_state {
-@@ -822,6 +823,7 @@ struct mt76_dev {
+@@ -825,6 +826,7 @@ struct mt76_dev {
  	spinlock_t status_lock;
  
  	u32 wcid_mask[DIV_ROUND_UP(MT76_N_WCIDS, 32)];
@@ -53,10 +52,10 @@
  
  	u64 vif_mask;
 diff --git a/mt7915/init.c b/mt7915/init.c
-index 6833bbf..8055c6e 100644
+index 69465dd0..039a5b01 100644
 --- a/mt7915/init.c
 +++ b/mt7915/init.c
-@@ -695,6 +695,15 @@ mt7915_init_hardware(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -719,6 +719,15 @@ mt7915_init_hardware(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  			return ret;
  	}
  
@@ -73,10 +72,10 @@
  	idx = mt76_wcid_alloc(dev->mt76.wcid_mask, MT7915_WTBL_STA);
  	if (idx)
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 4e91527..62b9658 100644
+index f9b2c1ef..c0617860 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -658,6 +658,24 @@ mt7915_channel_switch_beacon(struct ieee80211_hw *hw,
+@@ -660,6 +660,24 @@ mt7915_channel_switch_beacon(struct ieee80211_hw *hw,
  	mutex_unlock(&dev->mt76.mutex);
  }
  
@@ -101,7 +100,7 @@
  int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  		       struct ieee80211_sta *sta)
  {
-@@ -670,8 +688,18 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+@@ -672,8 +690,18 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  #endif
  	int ret, idx;
  	u32 addr;
@@ -121,7 +120,7 @@
  	if (idx < 0)
  		return -ENOSPC;
  
-@@ -1125,6 +1153,15 @@ static void mt7915_sta_set_4addr(struct ieee80211_hw *hw,
+@@ -1135,6 +1163,15 @@ static void mt7915_sta_set_4addr(struct ieee80211_hw *hw,
  	else
  		clear_bit(MT_WCID_FLAG_4ADDR, &msta->wcid.flags);
  
@@ -137,7 +136,7 @@
  	mt76_connac_mcu_wtbl_update_hdr_trans(&dev->mt76, vif, sta);
  }
  
-@@ -1464,7 +1501,11 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
+@@ -1473,7 +1510,11 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
  	path->dev = ctx->dev;
  	path->mtk_wdma.wdma_idx = wed->wdma_idx;
  	path->mtk_wdma.bss = mvif->mt76.idx;
@@ -151,18 +150,18 @@
  
  	ctx->dev = NULL;
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index d50482d..8f03a7d 100644
+index fad35595..eb9343ca 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2350,6 +2350,7 @@ mt7915_mcu_init_rx_airtime(struct mt7915_dev *dev)
- int mt7915_run_firmware(struct mt7915_dev *dev)
+@@ -2279,6 +2279,7 @@ mt7915_mcu_init_rx_airtime(struct mt7915_dev *dev)
+ int mt7915_mcu_init_firmware(struct mt7915_dev *dev)
  {
  	int ret;
 +	struct mtk_wed_device *wed = &dev->mt76.mmio.wed;
  
  	/* force firmware operation mode into normal state,
  	 * which should be set before firmware download stage.
-@@ -2379,8 +2380,15 @@ int mt7915_run_firmware(struct mt7915_dev *dev)
+@@ -2308,8 +2309,15 @@ int mt7915_mcu_init_firmware(struct mt7915_dev *dev)
  	if (ret)
  		return ret;
  
@@ -181,10 +180,10 @@
  	ret = mt7915_mcu_set_mwds(dev, 1);
  	if (ret)
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index 7738e96..cb95add 100644
+index b2e4032f..42d5e39f 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -268,6 +268,7 @@ enum {
+@@ -270,6 +270,7 @@ enum {
  	MCU_WA_PARAM_RED_SHOW_STA = 0xf,
  	MCU_WA_PARAM_RED_TARGET_DELAY = 0x10,
  #endif
@@ -193,10 +192,10 @@
  
  enum mcu_mmps_mode {
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 5819281..84a47c9 100644
+index f76f8967..e45cd2d5 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
-@@ -596,6 +596,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -646,6 +646,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  	wed->wlan.init_buf = mt7915_wed_init_buf;
  	wed->wlan.offload_enable = mt7915_mmio_wed_offload_enable;
  	wed->wlan.offload_disable = mt7915_mmio_wed_offload_disable;
@@ -205,7 +204,7 @@
  
  	if (mtk_wed_device_attach(wed))
  		return 0;
-@@ -810,6 +812,7 @@ struct mt7915_dev *mt7915_mmio_probe(struct device *pdev,
+@@ -860,6 +862,7 @@ struct mt7915_dev *mt7915_mmio_probe(struct device *pdev,
  		.sta_add = mt7915_mac_sta_add,
  		.sta_remove = mt7915_mac_sta_remove,
  		.update_survey = mt7915_update_channel,
@@ -214,7 +213,7 @@
  	struct mt7915_dev *dev;
  	struct mt76_dev *mdev;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index c8e9c3b..a20d4b8 100644
+index 527ec9ea..ba12a2d2 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
 @@ -18,6 +18,9 @@
@@ -227,7 +226,7 @@
  #define MT7915_WATCHDOG_TIME		(HZ / 10)
  #define MT7915_RESET_TIMEOUT		(30 * HZ)
  
-@@ -697,6 +700,7 @@ void mt7915_tx_token_put(struct mt7915_dev *dev);
+@@ -718,6 +721,7 @@ void mt7915_tx_token_put(struct mt7915_dev *dev);
  void mt7915_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
  			 struct sk_buff *skb);
  bool mt7915_rx_check(struct mt76_dev *mdev, void *data, int len);
diff --git a/recipes-wifi/linux-mt76/files/patches/3003-mt76-add-wed-rx-support.patch b/recipes-wifi/linux-mt76/files/patches/3003-mt76-add-wed-rx-support.patch
index 974ef99..3e775fd 100644
--- a/recipes-wifi/linux-mt76/files/patches/3003-mt76-add-wed-rx-support.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3003-mt76-add-wed-rx-support.patch
@@ -1,10 +1,9 @@
-From a242bbf9b619b24729315038c35b319d2cc314ef Mon Sep 17 00:00:00 2001
+From 30ccfabd2dccb876067ca6ca666a862a9c693bdc Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Tue, 5 Jul 2022 19:42:55 +0800
-Subject: [PATCH 3003/3010] mt76 add wed rx support
+Subject: [PATCH 3003/3011] mt76 add wed rx support
 
 Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  dma.c             | 250 ++++++++++++++++++++++++++++++++++++++--------
  dma.h             |  10 ++
@@ -29,7 +28,7 @@
  20 files changed, 448 insertions(+), 67 deletions(-)
 
 diff --git a/dma.c b/dma.c
-index 82b4da2..a8739eb 100644
+index 82b4da26..a8739eb4 100644
 --- a/dma.c
 +++ b/dma.c
 @@ -98,6 +98,63 @@ mt76_put_txwi(struct mt76_dev *dev, struct mt76_txwi_cache *t)
@@ -480,7 +479,7 @@
  }
  EXPORT_SYMBOL_GPL(mt76_dma_cleanup);
 diff --git a/dma.h b/dma.h
-index fdf786f..90370d1 100644
+index fdf786f9..90370d12 100644
 --- a/dma.h
 +++ b/dma.h
 @@ -16,6 +16,16 @@
@@ -501,7 +500,7 @@
  #define MT_RX_INFO_LEN			4
  #define MT_FCE_INFO_LEN			4
 diff --git a/mac80211.c b/mac80211.c
-index 1e13b65..3e27635 100644
+index c84c9ef0..32961b60 100644
 --- a/mac80211.c
 +++ b/mac80211.c
 @@ -603,11 +603,14 @@ mt76_alloc_device(struct device *pdev, unsigned int size,
@@ -519,7 +518,7 @@
  	dev->token_size = dev->drv->token_size;
  
  	for (i = 0; i < ARRAY_SIZE(dev->q_rx); i++)
-@@ -1305,7 +1308,10 @@ void mt76_rx_poll_complete(struct mt76_dev *dev, enum mt76_rxq_id q,
+@@ -1304,7 +1307,10 @@ void mt76_rx_poll_complete(struct mt76_dev *dev, enum mt76_rxq_id q,
  
  	while ((skb = __skb_dequeue(&dev->rx_skb[q])) != NULL) {
  		mt76_check_sta(dev, skb);
@@ -532,7 +531,7 @@
  
  	mt76_rx_complete(dev, &frames, napi);
 diff --git a/mt76.h b/mt76.h
-index 1888706..45439a7 100644
+index b86c8355..627bcbf9 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -20,6 +20,8 @@
@@ -581,7 +580,7 @@
  
  	void (*rx_poll_complete)(struct mt76_dev *dev, enum mt76_rxq_id q);
  
-@@ -779,6 +786,7 @@ struct mt76_dev {
+@@ -782,6 +789,7 @@ struct mt76_dev {
  	struct ieee80211_hw *hw;
  
  	spinlock_t lock;
@@ -589,7 +588,7 @@
  	spinlock_t cc_lock;
  
  	u32 cur_cc_bss_rx;
-@@ -804,6 +812,7 @@ struct mt76_dev {
+@@ -807,6 +815,7 @@ struct mt76_dev {
  	struct sk_buff_head rx_skb[__MT_RXQ_MAX];
  
  	struct list_head txwi_cache;
@@ -597,7 +596,7 @@
  	struct mt76_queue *q_mcu[__MT_MCUQ_MAX];
  	struct mt76_queue q_rx[__MT_RXQ_MAX];
  	const struct mt76_queue_ops *queue_ops;
-@@ -817,6 +826,9 @@ struct mt76_dev {
+@@ -820,6 +829,9 @@ struct mt76_dev {
  	u16 wed_token_count;
  	u16 token_count;
  	u16 token_size;
@@ -607,7 +606,7 @@
  
  	wait_queue_head_t tx_wait;
  	/* spinclock used to protect wcid pktid linked list */
-@@ -1359,6 +1371,8 @@ mt76_tx_status_get_hw(struct mt76_dev *dev, struct sk_buff *skb)
+@@ -1361,6 +1373,8 @@ mt76_tx_status_get_hw(struct mt76_dev *dev, struct sk_buff *skb)
  }
  
  void mt76_put_txwi(struct mt76_dev *dev, struct mt76_txwi_cache *t);
@@ -616,7 +615,7 @@
  void mt76_rx_complete(struct mt76_dev *dev, struct sk_buff_head *frames,
  		      struct napi_struct *napi);
  void mt76_rx_poll_complete(struct mt76_dev *dev, enum mt76_rxq_id q,
-@@ -1503,6 +1517,12 @@ struct mt76_txwi_cache *
+@@ -1505,6 +1519,12 @@ struct mt76_txwi_cache *
  mt76_token_release(struct mt76_dev *dev, int token, bool *wake);
  int mt76_token_consume(struct mt76_dev *dev, struct mt76_txwi_cache **ptxwi);
  void __mt76_set_tx_blocked(struct mt76_dev *dev, bool blocked);
@@ -630,7 +629,7 @@
  static inline void mt76_set_tx_blocked(struct mt76_dev *dev, bool blocked)
  {
 diff --git a/mt7603/dma.c b/mt7603/dma.c
-index 590cff9..2ff71c5 100644
+index 590cff9d..2ff71c53 100644
 --- a/mt7603/dma.c
 +++ b/mt7603/dma.c
 @@ -69,7 +69,7 @@ free:
@@ -643,7 +642,7 @@
  	struct mt7603_dev *dev = container_of(mdev, struct mt7603_dev, mt76);
  	__le32 *rxd = (__le32 *)skb->data;
 diff --git a/mt7603/mt7603.h b/mt7603/mt7603.h
-index 0fd46d9..f2ce22a 100644
+index 0fd46d90..f2ce22ae 100644
 --- a/mt7603/mt7603.h
 +++ b/mt7603/mt7603.h
 @@ -244,7 +244,7 @@ int mt7603_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
@@ -656,10 +655,10 @@
  void mt7603_sta_ps(struct mt76_dev *mdev, struct ieee80211_sta *sta, bool ps);
  int mt7603_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
 diff --git a/mt7615/mac.c b/mt7615/mac.c
-index 2ce1705..59125b4 100644
+index 305bf182..4aed123b 100644
 --- a/mt7615/mac.c
 +++ b/mt7615/mac.c
-@@ -1653,7 +1653,7 @@ bool mt7615_rx_check(struct mt76_dev *mdev, void *data, int len)
+@@ -1666,7 +1666,7 @@ bool mt7615_rx_check(struct mt76_dev *mdev, void *data, int len)
  EXPORT_SYMBOL_GPL(mt7615_rx_check);
  
  void mt7615_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
@@ -669,10 +668,10 @@
  	struct mt7615_dev *dev = container_of(mdev, struct mt7615_dev, mt76);
  	__le32 *rxd = (__le32 *)skb->data;
 diff --git a/mt7615/mt7615.h b/mt7615/mt7615.h
-index 060d52c..232b0f2 100644
+index 1080d202..91b30373 100644
 --- a/mt7615/mt7615.h
 +++ b/mt7615/mt7615.h
-@@ -511,7 +511,7 @@ void mt7615_tx_worker(struct mt76_worker *w);
+@@ -514,7 +514,7 @@ void mt7615_tx_worker(struct mt76_worker *w);
  void mt7615_tx_token_put(struct mt7615_dev *dev);
  bool mt7615_rx_check(struct mt76_dev *mdev, void *data, int len);
  void mt7615_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
@@ -682,7 +681,7 @@
  int mt7615_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
  		       struct ieee80211_sta *sta);
 diff --git a/mt76_connac_mcu.c b/mt76_connac_mcu.c
-index 01561a5..0f80090 100644
+index afdd42ff..1b01ef26 100644
 --- a/mt76_connac_mcu.c
 +++ b/mt76_connac_mcu.c
 @@ -1192,6 +1192,7 @@ int mt76_connac_mcu_sta_ba(struct mt76_dev *dev, struct mt76_vif *mvif,
@@ -711,7 +710,7 @@
  	return mt76_mcu_skb_send_msg(dev, skb, cmd, true);
  }
  EXPORT_SYMBOL_GPL(mt76_connac_mcu_sta_ba);
-@@ -2636,6 +2641,7 @@ int mt76_connac_mcu_add_key(struct mt76_dev *dev, struct ieee80211_vif *vif,
+@@ -2651,6 +2656,7 @@ int mt76_connac_mcu_add_key(struct mt76_dev *dev, struct ieee80211_vif *vif,
  			    struct mt76_wcid *wcid, enum set_key_cmd cmd)
  {
  	struct mt76_vif *mvif = (struct mt76_vif *)vif->drv_priv;
@@ -719,7 +718,7 @@
  	struct sk_buff *skb;
  	int ret;
  
-@@ -2647,6 +2653,9 @@ int mt76_connac_mcu_add_key(struct mt76_dev *dev, struct ieee80211_vif *vif,
+@@ -2662,6 +2668,9 @@ int mt76_connac_mcu_add_key(struct mt76_dev *dev, struct ieee80211_vif *vif,
  	if (ret)
  		return ret;
  
@@ -730,7 +729,7 @@
  }
  EXPORT_SYMBOL_GPL(mt76_connac_mcu_add_key);
 diff --git a/mt76x02.h b/mt76x02.h
-index 849c264..49112ab 100644
+index 849c2644..49112ab6 100644
 --- a/mt76x02.h
 +++ b/mt76x02.h
 @@ -187,7 +187,7 @@ int mt76x02_set_rts_threshold(struct ieee80211_hw *hw, u32 val);
@@ -743,7 +742,7 @@
  irqreturn_t mt76x02_irq_handler(int irq, void *dev_instance);
  void mt76x02_tx(struct ieee80211_hw *hw, struct ieee80211_tx_control *control,
 diff --git a/mt76x02_txrx.c b/mt76x02_txrx.c
-index 3a31307..5d6c8f7 100644
+index 3a313075..5d6c8f71 100644
 --- a/mt76x02_txrx.c
 +++ b/mt76x02_txrx.c
 @@ -33,7 +33,7 @@ void mt76x02_tx(struct ieee80211_hw *hw, struct ieee80211_tx_control *control,
@@ -756,10 +755,10 @@
  	struct mt76x02_dev *dev = container_of(mdev, struct mt76x02_dev, mt76);
  	void *rxwi = skb->data;
 diff --git a/mt7915/dma.c b/mt7915/dma.c
-index e391886..702d629 100644
+index 9a57ad8f..6f6550f5 100644
 --- a/mt7915/dma.c
 +++ b/mt7915/dma.c
-@@ -344,7 +344,8 @@ static int mt7915_dma_enable(struct mt7915_dev *dev)
+@@ -365,7 +365,8 @@ static int mt7915_dma_enable(struct mt7915_dev *dev)
  		wed_irq_mask |= MT_INT_TX_DONE_BAND0 | MT_INT_TX_DONE_BAND1;
  		if (!is_mt7986(&dev->mt76))
  			mt76_wr(dev, MT_INT_WED_MASK_CSR, wed_irq_mask);
@@ -769,7 +768,7 @@
  		mtk_wed_device_start(&dev->mt76.mmio.wed, wed_irq_mask);
  	}
  
-@@ -356,6 +357,7 @@ static int mt7915_dma_enable(struct mt7915_dev *dev)
+@@ -377,6 +378,7 @@ static int mt7915_dma_enable(struct mt7915_dev *dev)
  int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  {
  	struct mt76_dev *mdev = &dev->mt76;
@@ -777,7 +776,7 @@
  	u32 wa_rx_base, wa_rx_idx;
  	u32 hif1_ofs = 0;
  	int ret;
-@@ -380,6 +382,9 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -401,6 +403,9 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  				FIELD_PREP(MT_WFDMA_WED_RING_CONTROL_TX1, 19) |
  				FIELD_PREP(MT_WFDMA_WED_RING_CONTROL_RX1,
  					   wed_control_rx1));
@@ -787,7 +786,7 @@
  		}
  	} else {
  		mt76_clear(dev, MT_WFDMA_HOST_CONFIG, MT_WFDMA_HOST_CONFIG_WED);
-@@ -452,6 +457,11 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -473,6 +478,11 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  
  	/* rx data queue for band0 */
  	if (!dev->phy.band_idx) {
@@ -799,7 +798,7 @@
  		ret = mt76_queue_alloc(dev, &dev->mt76.q_rx[MT_RXQ_MAIN],
  				       MT_RXQ_ID(MT_RXQ_MAIN),
  				       MT7915_RX_RING_SIZE,
-@@ -482,6 +492,11 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -503,6 +513,11 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  	}
  
  	if (dev->dbdc_support || dev->phy.band_idx) {
@@ -812,10 +811,10 @@
  		ret = mt76_queue_alloc(dev, &dev->mt76.q_rx[MT_RXQ_BAND1],
  				       MT_RXQ_ID(MT_RXQ_BAND1),
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 98925ed..1ef7cb4 100644
+index 20e5b705..eac49465 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -217,7 +217,7 @@ static void mt7915_mac_sta_poll(struct mt7915_dev *dev)
+@@ -247,7 +247,7 @@ void mt7915_mac_enable_rtscts(struct mt7915_dev *dev,
  }
  
  static int
@@ -824,7 +823,7 @@
  {
  	struct mt76_rx_status *status = (struct mt76_rx_status *)skb->cb;
  	struct mt76_phy *mphy = &dev->mt76.phy;
-@@ -496,6 +496,27 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
+@@ -526,6 +526,27 @@ mt7915_mac_fill_rx(struct mt7915_dev *dev, struct sk_buff *skb)
  #endif
  	} else {
  		status->flag |= RX_FLAG_8023;
@@ -852,7 +851,7 @@
  	}
  
  	if (rxv && mode >= MT_PHY_TYPE_HE_SU && !(status->flag & RX_FLAG_8023))
-@@ -833,6 +854,80 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id)
+@@ -863,6 +884,80 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id)
  	return MT_TXD_TXP_BUF_SIZE;
  }
  
@@ -933,7 +932,7 @@
  static void
  mt7915_tx_check_aggr(struct ieee80211_sta *sta, __le32 *txwi)
  {
-@@ -1117,7 +1212,7 @@ bool mt7915_rx_check(struct mt76_dev *mdev, void *data, int len)
+@@ -1147,7 +1242,7 @@ bool mt7915_rx_check(struct mt76_dev *mdev, void *data, int len)
  }
  
  void mt7915_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
@@ -942,7 +941,7 @@
  {
  	struct mt7915_dev *dev = container_of(mdev, struct mt7915_dev, mt76);
  	__le32 *rxd = (__le32 *)skb->data;
-@@ -1151,7 +1246,7 @@ void mt7915_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
+@@ -1181,7 +1276,7 @@ void mt7915_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
  		dev_kfree_skb(skb);
  		break;
  	case PKT_TYPE_NORMAL:
@@ -952,10 +951,10 @@
  			return;
  		}
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 8f03a7d..79c7eff 100644
+index eb9343ca..c11e575a 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -1724,6 +1724,7 @@ int mt7915_mcu_add_sta(struct mt7915_dev *dev, struct ieee80211_vif *vif,
+@@ -1653,6 +1653,7 @@ int mt7915_mcu_add_sta(struct mt7915_dev *dev, struct ieee80211_vif *vif,
  		       struct ieee80211_sta *sta, bool enable)
  {
  	struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv;
@@ -963,7 +962,7 @@
  	struct mt7915_sta *msta;
  	struct sk_buff *skb;
  	int ret;
-@@ -1776,6 +1777,8 @@ int mt7915_mcu_add_sta(struct mt7915_dev *dev, struct ieee80211_vif *vif,
+@@ -1705,6 +1706,8 @@ int mt7915_mcu_add_sta(struct mt7915_dev *dev, struct ieee80211_vif *vif,
  		return ret;
  	}
  out:
@@ -973,34 +972,34 @@
  				     MCU_EXT_CMD(STA_REC_UPDATE), true);
  }
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 84a47c9..45520c7 100644
+index e45cd2d5..1e22ec98 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
-@@ -29,6 +29,7 @@ static const u32 mt7915_reg[] = {
+@@ -44,6 +44,7 @@ static const u32 mt7915_reg[] = {
  	[SWDEF_BASE_ADDR]	= 0x41f200,
  	[TXQ_WED_RING_BASE]	= 0xd7300,
  	[RXQ_WED_RING_BASE]	= 0xd7410,
 +	[WED_RX_DATA_RING]	= 0xd4500,
- 	[EXCEPTION_BASE_ADDR]	= 0x219848,
  };
  
-@@ -48,6 +49,7 @@ static const u32 mt7916_reg[] = {
+ static const u32 mt7916_reg[] = {
+@@ -77,6 +78,7 @@ static const u32 mt7916_reg[] = {
  	[SWDEF_BASE_ADDR]	= 0x411400,
  	[TXQ_WED_RING_BASE]	= 0xd7300,
  	[RXQ_WED_RING_BASE]	= 0xd7410,
 +	[WED_RX_DATA_RING]	= 0xd4540,
- 	[EXCEPTION_BASE_ADDR]	= 0x022050BC,
  };
  
-@@ -67,6 +69,7 @@ static const u32 mt7986_reg[] = {
+ static const u32 mt7986_reg[] = {
+@@ -110,6 +112,7 @@ static const u32 mt7986_reg[] = {
  	[SWDEF_BASE_ADDR]	= 0x411400,
  	[TXQ_WED_RING_BASE]	= 0x24420,
  	[RXQ_WED_RING_BASE]	= 0x24520,
 +	[WED_RX_DATA_RING]	= 0x24540,
- 	[EXCEPTION_BASE_ADDR]	= 0x02204FFC,
  };
  
-@@ -555,7 +558,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+ static const u32 mt7915_offs[] = {
+@@ -605,7 +608,7 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  		struct pci_dev *pci_dev = pdev_ptr;
  
  		wed->wlan.pci_dev = pci_dev;
@@ -1009,7 +1008,7 @@
  		wed->wlan.base = (void __iomem *)ioremap(
  				 pci_resource_start(pci_dev, 0),
  				 pci_resource_len(pci_dev, 0));
-@@ -569,6 +572,10 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -619,6 +622,10 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  				     MT_TXQ_WED_RING_BASE;
  		wed->wlan.wpdma_txfree = pci_resource_start(pci_dev, 0) +
  					 MT_RXQ_WED_RING_BASE;
@@ -1020,7 +1019,7 @@
  		wed->wlan.phy_base = pci_resource_start(pci_dev, 0);
  	} else {
  		struct platform_device *plat_dev = pdev_ptr;
-@@ -578,27 +585,38 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -628,27 +635,38 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  		if (!res)
  			return -ENOMEM;
  
@@ -1065,7 +1064,7 @@
  		return 0;
  
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index a20d4b8..346571a 100644
+index ba12a2d2..acc345a2 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
 @@ -81,6 +81,7 @@
@@ -1076,7 +1075,7 @@
  
  struct mt7915_vif;
  struct mt7915_sta;
-@@ -544,7 +545,9 @@ void mt7915_wfsys_reset(struct mt7915_dev *dev);
+@@ -559,7 +560,9 @@ void mt7915_wfsys_reset(struct mt7915_dev *dev);
  irqreturn_t mt7915_irq_handler(int irq, void *dev_instance);
  u64 __mt7915_get_tsf(struct ieee80211_hw *hw, struct mt7915_vif *mvif);
  u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
@@ -1087,7 +1086,7 @@
  int mt7915_register_device(struct mt7915_dev *dev);
  void mt7915_unregister_device(struct mt7915_dev *dev);
  void mt7915_eeprom_rebonding(struct mt7915_dev *dev);
-@@ -698,7 +701,7 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
+@@ -719,7 +722,7 @@ int mt7915_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
  			  struct mt76_tx_info *tx_info);
  void mt7915_tx_token_put(struct mt7915_dev *dev);
  void mt7915_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
@@ -1097,18 +1096,18 @@
  bool mt7915_wed_wds_check(struct mt76_dev *mdev, struct ieee80211_sta *sta);
  void mt7915_sta_ps(struct mt76_dev *mdev, struct ieee80211_sta *sta, bool ps);
 diff --git a/mt7915/regs.h b/mt7915/regs.h
-index 8fd2f69..36ad243 100644
+index 9b6266c1..faaac08c 100644
 --- a/mt7915/regs.h
 +++ b/mt7915/regs.h
-@@ -28,6 +28,7 @@ enum reg_rev {
+@@ -43,6 +43,7 @@ enum reg_rev {
  	SWDEF_BASE_ADDR,
  	TXQ_WED_RING_BASE,
  	RXQ_WED_RING_BASE,
 +	WED_RX_DATA_RING,
- 	EXCEPTION_BASE_ADDR,
  	__MT_REG_MAX,
  };
-@@ -570,9 +571,13 @@ enum offs_rev {
+ 
+@@ -603,9 +604,13 @@ enum offs_rev {
  #define MT_WFDMA0_GLO_CFG_OMIT_RX_INFO_PFET2	BIT(21)
  
  #define MT_WFDMA0_RST_DTX_PTR		MT_WFDMA0(0x20c)
@@ -1120,9 +1119,9 @@
  #define MT_WFDMA0_PRI_DLY_INT_CFG2	MT_WFDMA0(0x2f8)
 +#define MT_WPDMA_GLO_CFG		MT_WFDMA0(0x208)
  
- #define MT_WFDMA0_MCU_HOST_INT_ENA	MT_WFDMA0(0x1f4)
- #define MT_WFDMA0_MT_WA_WDT_INT		BIT(31)
-@@ -672,6 +677,7 @@ enum offs_rev {
+ /* WFDMA1 */
+ #define MT_WFDMA1_BASE			0xd5000
+@@ -701,6 +706,7 @@ enum offs_rev {
  
  #define MT_TXQ_WED_RING_BASE		__REG(TXQ_WED_RING_BASE)
  #define MT_RXQ_WED_RING_BASE		__REG(RXQ_WED_RING_BASE)
@@ -1131,7 +1130,7 @@
  #define MT_INT_SOURCE_CSR		__REG(INT_SOURCE_CSR)
  #define MT_INT_MASK_CSR			__REG(INT_MASK_CSR)
 diff --git a/mt7921/mac.c b/mt7921/mac.c
-index 1abf7d9..2ad7b33 100644
+index 7b15193c..ea6dd953 100644
 --- a/mt7921/mac.c
 +++ b/mt7921/mac.c
 @@ -692,7 +692,7 @@ bool mt7921_rx_check(struct mt76_dev *mdev, void *data, int len)
@@ -1144,10 +1143,10 @@
  	struct mt7921_dev *dev = container_of(mdev, struct mt7921_dev, mt76);
  	__le32 *rxd = (__le32 *)skb->data;
 diff --git a/mt7921/mt7921.h b/mt7921/mt7921.h
-index eaba114..54a30ca 100644
+index d9d78f6b..0c9924a5 100644
 --- a/mt7921/mt7921.h
 +++ b/mt7921/mt7921.h
-@@ -408,7 +408,7 @@ void mt7921_tx_worker(struct mt76_worker *w);
+@@ -422,7 +422,7 @@ void mt7921_tx_worker(struct mt76_worker *w);
  void mt7921_tx_token_put(struct mt7921_dev *dev);
  bool mt7921_rx_check(struct mt76_dev *mdev, void *data, int len);
  void mt7921_queue_rx_skb(struct mt76_dev *mdev, enum mt76_rxq_id q,
@@ -1157,7 +1156,7 @@
  void mt7921_stats_work(struct work_struct *work);
  void mt7921_set_stream_he_caps(struct mt7921_phy *phy);
 diff --git a/tx.c b/tx.c
-index 8b33186..b812d06 100644
+index 8b33186b..b812d067 100644
 --- a/tx.c
 +++ b/tx.c
 @@ -778,3 +778,37 @@ mt76_token_release(struct mt76_dev *dev, int token, bool *wake)
diff --git a/recipes-wifi/linux-mt76/files/patches/3004-mt76-add-fill-receive-path-to-report-wed-idx.patch b/recipes-wifi/linux-mt76/files/patches/3004-mt76-add-fill-receive-path-to-report-wed-idx.patch
index 400080f..30791ea 100644
--- a/recipes-wifi/linux-mt76/files/patches/3004-mt76-add-fill-receive-path-to-report-wed-idx.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3004-mt76-add-fill-receive-path-to-report-wed-idx.patch
@@ -1,19 +1,18 @@
-From 725852c4a994b35b6b9320b153175df5d910b867 Mon Sep 17 00:00:00 2001
+From d9b8f90612abf82f99013762ec38113a4463de6d Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Thu, 19 May 2022 13:44:42 +0800
-Subject: [PATCH 3004/3010] mt76: add fill receive path to report wed idx
+Subject: [PATCH 3004/3011] mt76: add fill receive path to report wed idx
 
 Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mt7915/main.c | 19 +++++++++++++++++++
  1 file changed, 19 insertions(+)
 
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 62b9658..5e37c4c 100644
+index c0617860..84b90010 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -1512,6 +1512,24 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
+@@ -1521,6 +1521,24 @@ mt7915_net_fill_forward_path(struct ieee80211_hw *hw,
  
  	return 0;
  }
@@ -38,7 +37,7 @@
  #endif
  
  const struct ieee80211_ops mt7915_ops = {
-@@ -1563,5 +1581,6 @@ const struct ieee80211_ops mt7915_ops = {
+@@ -1572,5 +1590,6 @@ const struct ieee80211_ops mt7915_ops = {
  	.set_radar_background = mt7915_set_radar_background,
  #ifdef CONFIG_NET_MEDIATEK_SOC_WED
  	.net_fill_forward_path = mt7915_net_fill_forward_path,
diff --git a/recipes-wifi/linux-mt76/files/patches/3005-mt76-add-ser-spport-when-wed-on.patch b/recipes-wifi/linux-mt76/files/patches/3005-mt76-add-ser-spport-when-wed-on.patch
index 8fc8e61..3fc96e6 100644
--- a/recipes-wifi/linux-mt76/files/patches/3005-mt76-add-ser-spport-when-wed-on.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3005-mt76-add-ser-spport-when-wed-on.patch
@@ -1,10 +1,9 @@
-From fcd960471fe61d47225ac1da974e64a2700cd797 Mon Sep 17 00:00:00 2001
+From cfa2b02b3cbc63ccf936d0620c36ed5a5c841cb7 Mon Sep 17 00:00:00 2001
 From: Sujuan Chen <sujuan.chen@mediatek.com>
 Date: Thu, 28 Jul 2022 11:16:15 +0800
-Subject: [PATCH 3005/3010] mt76 add ser spport when wed on
+Subject: [PATCH 3005/3011] mt76 add ser spport when wed on
 
 Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  dma.c           | 29 ++++++++++++++++++++---------
  dma.h           |  2 +-
@@ -16,7 +15,7 @@
  7 files changed, 76 insertions(+), 15 deletions(-)
 
 diff --git a/dma.c b/dma.c
-index a8739eb..d63b02f 100644
+index a8739eb4..d63b02f5 100644
 --- a/dma.c
 +++ b/dma.c
 @@ -169,7 +169,7 @@ mt76_free_pending_txwi(struct mt76_dev *dev)
@@ -110,7 +109,7 @@
  	if (!q->rx_head)
  		return;
 diff --git a/dma.h b/dma.h
-index 90370d1..083cbca 100644
+index 90370d12..083cbca4 100644
 --- a/dma.h
 +++ b/dma.h
 @@ -58,5 +58,5 @@ enum mt76_mcu_evt_type {
@@ -121,10 +120,10 @@
 +int mt76_dma_wed_setup(struct mt76_dev *dev, struct mt76_queue *q, bool reset);
  #endif
 diff --git a/mt76.h b/mt76.h
-index 45439a7..13bdc08 100644
+index 627bcbf9..f22e96e0 100644
 --- a/mt76.h
 +++ b/mt76.h
-@@ -1373,6 +1373,7 @@ mt76_tx_status_get_hw(struct mt76_dev *dev, struct sk_buff *skb)
+@@ -1375,6 +1375,7 @@ mt76_tx_status_get_hw(struct mt76_dev *dev, struct sk_buff *skb)
  void mt76_put_txwi(struct mt76_dev *dev, struct mt76_txwi_cache *t);
  void mt76_put_rxwi(struct mt76_dev *dev, struct mt76_txwi_cache *t);
  struct mt76_txwi_cache *mt76_get_rxwi(struct mt76_dev *dev);
@@ -133,10 +132,10 @@
  		      struct napi_struct *napi);
  void mt76_rx_poll_complete(struct mt76_dev *dev, enum mt76_rxq_id q,
 diff --git a/mt7915/dma.c b/mt7915/dma.c
-index 702d629..96cad2b 100644
+index 6f6550f5..8edfa465 100644
 --- a/mt7915/dma.c
 +++ b/mt7915/dma.c
-@@ -532,6 +532,7 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -553,6 +553,7 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
  int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
  {
  	struct mt76_phy *mphy_ext = dev->mt76.phys[MT_BAND1];
@@ -144,10 +143,10 @@
  	int i;
  
  	/* clean up hw queues */
-@@ -552,28 +553,53 @@ int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
+@@ -572,28 +573,53 @@ int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
+ 	if (force)
  		mt7915_wfsys_reset(dev);
  
- 	/* disable wfdma */
 +	if (mtk_wed_device_active(&dev->mt76.mmio.wed))
 +		mtk_wed_device_dma_reset(&dev->mt76.mmio.wed);
  	mt7915_dma_disable(dev, force);
@@ -204,10 +203,10 @@
  }
  
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 1ef7cb4..e78f30f 100644
+index eac49465..cbdabea0 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -918,6 +918,8 @@ void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed)
+@@ -948,6 +948,8 @@ void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed)
  		mt76_put_rxwi(&dev->mt76, rxwi);
  	}
  
@@ -216,7 +215,7 @@
  	if (wed->rx_page.va)
  		return;
  
-@@ -928,6 +930,18 @@ void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed)
+@@ -958,6 +960,18 @@ void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed)
  	return;
  }
  
@@ -235,8 +234,8 @@
  static void
  mt7915_tx_check_aggr(struct ieee80211_sta *sta, __le32 *txwi)
  {
-@@ -1681,6 +1695,12 @@ void mt7915_mac_reset_work(struct work_struct *work)
- 	if (!(READ_ONCE(dev->reset_state) & MT_MCU_CMD_STOP_DMA))
+@@ -1697,6 +1711,12 @@ void mt7915_mac_reset_work(struct work_struct *work)
+ 	if (!(READ_ONCE(dev->recovery.state) & MT_MCU_CMD_STOP_DMA))
  		return;
  
 +	if (mtk_wed_device_active(&dev->mt76.mmio.wed)) {
@@ -249,10 +248,10 @@
  	if (ext_phy)
  		ieee80211_stop_queues(ext_phy->hw);
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 45520c7..6a1877d 100644
+index 1e22ec98..60b7886c 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
-@@ -616,6 +616,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -666,6 +666,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  	wed->wlan.init_rx_buf = mt7915_wed_init_rx_buf;
  	wed->wlan.release_rx_buf = mt7915_wed_release_rx_buf;
  
@@ -262,10 +261,10 @@
  	if (mtk_wed_device_attach(wed))
  		return 0;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 346571a..412f4f4 100644
+index acc345a2..55fe6343 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -548,6 +548,7 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
+@@ -563,6 +563,7 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
  u32 mt7915_wed_init_rx_buf(struct mtk_wed_device *wed,
  				int pkt_num);
  void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed);
diff --git a/recipes-wifi/linux-mt76/files/patches/3006-mt76-mt7915-add-statistic-for-H-W-Rx-Path.patch b/recipes-wifi/linux-mt76/files/patches/3006-mt76-mt7915-add-statistic-for-H-W-Rx-Path.patch
index 4d886be..3941f41 100644
--- a/recipes-wifi/linux-mt76/files/patches/3006-mt76-mt7915-add-statistic-for-H-W-Rx-Path.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3006-mt76-mt7915-add-statistic-for-H-W-Rx-Path.patch
@@ -1,10 +1,9 @@
-From 301353df129dc70115481141357c590b4362a5c8 Mon Sep 17 00:00:00 2001
+From 209aeac176b9760b9de5889cb67f674900864633 Mon Sep 17 00:00:00 2001
 From: Yi-Chia Hsieh <Yi-Chia.Hsieh@mediatek.com>
 Date: Fri, 5 Aug 2022 13:58:11 -0700
-Subject: [PATCH 3006/3010] mt76: mt7915: add statistic for H/W Rx Path
+Subject: [PATCH 3006/3011] mt76: mt7915: add statistic for H/W Rx Path
 
 Change-Id: Id94d663f08e91c83d296bd57e5e9b65a505ae1c7
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mt76.h          |  4 ++++
  mt7915/mac.c    | 25 +++++++++++++++++++++++++
@@ -14,7 +13,7 @@
  5 files changed, 56 insertions(+), 1 deletion(-)
 
 diff --git a/mt76.h b/mt76.h
-index 13bdc08..14c58bc 100644
+index f22e96e0..8011d4ca 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -278,6 +278,10 @@ struct mt76_sta_stats {
@@ -29,10 +28,10 @@
  
  enum mt76_wcid_flags {
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index e78f30f..7fb161d 100644
+index cbdabea0..f1d15d85 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -942,6 +942,31 @@ void mt7915_wed_trigger_ser(struct mtk_wed_device *wed)
+@@ -972,6 +972,31 @@ void mt7915_wed_trigger_ser(struct mtk_wed_device *wed)
  	return;
  }
  
@@ -65,10 +64,10 @@
  mt7915_tx_check_aggr(struct ieee80211_sta *sta, __le32 *txwi)
  {
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 5e37c4c..01d64b2 100644
+index 84b90010..4ac5259d 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
-@@ -1050,7 +1050,8 @@ static void mt7915_sta_statistics(struct ieee80211_hw *hw,
+@@ -1054,7 +1054,8 @@ static void mt7915_sta_statistics(struct ieee80211_hw *hw,
  	struct rate_info *txrate = &msta->wcid.rate;
  	struct rate_info rxrate = {};
  
@@ -78,7 +77,7 @@
  	    !mt7915_mcu_get_rx_rate(phy, vif, sta, &rxrate)) {
  		sinfo->rxrate = rxrate;
  		sinfo->filled |= BIT_ULL(NL80211_STA_INFO_RX_BITRATE);
-@@ -1087,6 +1088,12 @@ static void mt7915_sta_statistics(struct ieee80211_hw *hw,
+@@ -1091,6 +1092,12 @@ static void mt7915_sta_statistics(struct ieee80211_hw *hw,
  
  		sinfo->tx_retries = msta->wcid.stats.tx_retries;
  		sinfo->filled |= BIT_ULL(NL80211_STA_INFO_TX_RETRIES);
@@ -89,10 +88,10 @@
 +		sinfo->rx_packets = msta->wcid.stats.rx_packets;
 +		sinfo->filled |= BIT_ULL(NL80211_STA_INFO_RX_PACKETS);
  	}
- }
  
+ 	sinfo->ack_signal = (s8)msta->ack_signal;
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 6a1877d..cd8326b 100644
+index 60b7886c..f3144d15 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
 @@ -9,6 +9,7 @@
@@ -103,7 +102,7 @@
  
  static bool wed_enable = true;
  module_param(wed_enable, bool, 0644);
-@@ -618,6 +619,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -668,6 +669,8 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  
  	wed->wlan.ser_trigger = mt7915_wed_trigger_ser;
  
@@ -112,7 +111,7 @@
  	dev->mt76.rx_token_size = wed->wlan.rx_pkt;
  	if (mtk_wed_device_attach(wed))
  		return 0;
-@@ -630,6 +633,20 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
+@@ -680,6 +683,20 @@ int mt7915_mmio_wed_init(struct mt7915_dev *dev, void *pdev_ptr,
  	if (ret)
  		return ret;
  
@@ -134,10 +133,10 @@
  #else
  	return 0;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 412f4f4..9977162 100644
+index 55fe6343..40161cf6 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -549,6 +549,8 @@ u32 mt7915_wed_init_rx_buf(struct mtk_wed_device *wed,
+@@ -564,6 +564,8 @@ u32 mt7915_wed_init_rx_buf(struct mtk_wed_device *wed,
  				int pkt_num);
  void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed);
  void mt7915_wed_trigger_ser(struct mtk_wed_device *wed);
diff --git a/recipes-wifi/linux-mt76/files/patches/3007-mt76-mt7915-enable-red-per-band-token-drop-for-HW-Pa.patch b/recipes-wifi/linux-mt76/files/patches/3007-mt76-mt7915-enable-red-per-band-token-drop-for-HW-Pa.patch
index 57ec82a..9e0bb9f 100644
--- a/recipes-wifi/linux-mt76/files/patches/3007-mt76-mt7915-enable-red-per-band-token-drop-for-HW-Pa.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3007-mt76-mt7915-enable-red-per-band-token-drop-for-HW-Pa.patch
@@ -1,7 +1,7 @@
-From 7953cd4cc8b1f91e56ee6cae491a227bafe5f81e Mon Sep 17 00:00:00 2001
+From 3abad81e25879921c6b6a0403880f7a83f1e6503 Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Fri, 2 Sep 2022 14:40:40 +0800
-Subject: [PATCH 3007/3010] mt76: mt7915: enable red per-band token drop for HW
+Subject: [PATCH 3007/3011] mt76: mt7915: enable red per-band token drop for HW
  Path
 
 Limit the number of token used by each band. If a band uses too many token,
@@ -9,7 +9,6 @@
 problem by AQL.
 
 Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mt7915/mcu.c    | 53 +++++++++++++++++++++++++++++++++++++++----------
  mt7915/mcu.h    |  1 +
@@ -17,10 +16,10 @@
  3 files changed, 45 insertions(+), 11 deletions(-)
 
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index eda4f70..b98c8e8 100644
+index c11e575a..ad2d6a39 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
-@@ -2412,8 +2412,13 @@ int mt7915_run_firmware(struct mt7915_dev *dev)
+@@ -2320,8 +2320,13 @@ int mt7915_mcu_init_firmware(struct mt7915_dev *dev)
  			mt7915_mcu_wa_cmd(dev, MCU_WA_PARAM_CMD(SET),
  					  MCU_WA_PARAM_WED_VERSION,
  					  wed->rev_id, 0);
@@ -34,7 +33,7 @@
  	ret = mt7915_mcu_set_mwds(dev, 1);
  	if (ret)
  		return ret;
-@@ -2423,12 +2428,7 @@ int mt7915_run_firmware(struct mt7915_dev *dev)
+@@ -2331,12 +2336,7 @@ int mt7915_mcu_init_firmware(struct mt7915_dev *dev)
  	if (ret)
  		return ret;
  
@@ -48,7 +47,7 @@
  }
  
  int mt7915_mcu_init(struct mt7915_dev *dev)
-@@ -4239,6 +4239,35 @@ int mt7915_dbg_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a
+@@ -4162,6 +4162,35 @@ int mt7915_dbg_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a
  
  	return mt76_mcu_send_msg(&dev->mt76, cmd, &req, sizeof(req), wait_resp);
  }
@@ -84,7 +83,7 @@
  
  int mt7915_mcu_set_red(struct mt7915_dev *dev, bool enabled)
  {
-@@ -4249,17 +4278,21 @@ int mt7915_mcu_set_red(struct mt7915_dev *dev, bool enabled)
+@@ -4172,17 +4201,21 @@ int mt7915_mcu_set_red(struct mt7915_dev *dev, bool enabled)
  	u32 red_type = enabled > 0 ? RED_BY_WA_ENABLE : RED_DISABLE;
  	__le32 req = cpu_to_le32(red_type);
  
@@ -111,10 +110,10 @@
  int mt7915_mcu_rf_regval(struct mt7915_dev *dev, u32 regidx, u32 *val, bool set)
  {
 diff --git a/mt7915/mcu.h b/mt7915/mcu.h
-index cb95add..4071a73 100644
+index 42d5e39f..3e892358 100644
 --- a/mt7915/mcu.h
 +++ b/mt7915/mcu.h
-@@ -269,6 +269,7 @@ enum {
+@@ -271,6 +271,7 @@ enum {
  	MCU_WA_PARAM_RED_TARGET_DELAY = 0x10,
  #endif
  	MCU_WA_PARAM_WED_VERSION = 0x32,
@@ -123,10 +122,10 @@
  
  enum mcu_mmps_mode {
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 9977162..e0c0b49 100644
+index 40161cf6..d93c394c 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -753,6 +753,7 @@ int mt7915_vendor_amnt_sta_remove(struct mt7915_phy *phy,
+@@ -773,6 +773,7 @@ int mt7915_vendor_amnt_sta_remove(struct mt7915_phy *phy,
  #endif
  int mt7915_mcu_set_edcca(struct mt7915_phy *phy, int mode, u8 *value,
  			 s8 compensation);
@@ -134,7 +133,7 @@
  
  int mt7915_mcu_ipi_hist_ctrl(struct mt7915_phy *phy, void *data, u8 cmd, bool wait_resp);
  int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool wait_resp);
-@@ -760,7 +761,6 @@ int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool w
+@@ -780,7 +781,6 @@ int mt7915_mcu_ipi_hist_scan(struct mt7915_phy *phy, void *data, u8 mode, bool w
  #ifdef MTK_DEBUG
  int mt7915_mtk_init_debugfs(struct mt7915_phy *phy, struct dentry *dir);
  int mt7915_dbg_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a3, bool wait_resp);
diff --git a/recipes-wifi/linux-mt76/files/patches/3008-mt76-mt7915-update-mt7916-trinfo-when-hw-path-enable.patch b/recipes-wifi/linux-mt76/files/patches/3008-mt76-mt7915-update-mt7916-trinfo-when-hw-path-enable.patch
index 87b609b..b4f0889 100644
--- a/recipes-wifi/linux-mt76/files/patches/3008-mt76-mt7915-update-mt7916-trinfo-when-hw-path-enable.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3008-mt76-mt7915-update-mt7916-trinfo-when-hw-path-enable.patch
@@ -1,17 +1,16 @@
-From a75a445f60dd12ccd14c21e04eb5bab872546926 Mon Sep 17 00:00:00 2001
+From a80ea5a70e2353d61feadcdcd6d590b31a6d0eaf Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Thu, 22 Sep 2022 09:54:53 +0800
-Subject: [PATCH 3008/3010] mt76: mt7915: update mt7916 trinfo when hw path
+Subject: [PATCH 3008/3011] mt76: mt7915: update mt7916 trinfo when hw path
  enable
 
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  mt7915/mt7915_debug.h | 10 ++++++++++
  mt7915/mtk_debugfs.c  | 16 +++++++++++++---
  2 files changed, 23 insertions(+), 3 deletions(-)
 
 diff --git a/mt7915/mt7915_debug.h b/mt7915/mt7915_debug.h
-index ecdc02a..0a1ee80 100644
+index ecdc02ab..0a1ee808 100644
 --- a/mt7915/mt7915_debug.h
 +++ b/mt7915/mt7915_debug.h
 @@ -133,6 +133,8 @@ enum dbg_reg_rev {
@@ -58,7 +57,7 @@
  #define MT_DBG_INT_SOURCE_CSR			__DBG_REG(dev, DBG_INT_SOURCE_CSR)
  #define MT_DBG_INT_MASK_CSR			__DBG_REG(dev, DBG_INT_MASK_CSR)
 diff --git a/mt7915/mtk_debugfs.c b/mt7915/mtk_debugfs.c
-index c5e0472..41bd0ff 100644
+index c5e04728..41bd0ff1 100644
 --- a/mt7915/mtk_debugfs.c
 +++ b/mt7915/mtk_debugfs.c
 @@ -855,12 +855,22 @@ mt7986_show_host_dma_info(struct seq_file *s, struct mt7915_dev *dev)
diff --git a/recipes-wifi/linux-mt76/files/patches/3009-mt76-mt7915-find-rx-token-by-physical-address.patch b/recipes-wifi/linux-mt76/files/patches/3009-mt76-mt7915-find-rx-token-by-physical-address.patch
index 4555f30..7c2bb77 100644
--- a/recipes-wifi/linux-mt76/files/patches/3009-mt76-mt7915-find-rx-token-by-physical-address.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3009-mt76-mt7915-find-rx-token-by-physical-address.patch
@@ -1,19 +1,18 @@
-From ee742fbd2c1d7334553fc07787fca09b227e71f5 Mon Sep 17 00:00:00 2001
+From 70c17335911119c353fdf709d8ce1688509c02d0 Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Tue, 27 Sep 2022 16:34:26 +0800
-Subject: [PATCH 3009/3010] mt76: mt7915: find rx token by physical address
+Subject: [PATCH 3009/3011] mt76: mt7915: find rx token by physical address
 
 The token id in RxDMAD may be incorrect when it is not the last frame due to
 WED HW bug. Lookup correct token id by physical address in sdp0.
 
 Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  dma.c | 19 ++++++++++++++++++-
  1 file changed, 18 insertions(+), 1 deletion(-)
 
 diff --git a/dma.c b/dma.c
-index d63b02f..a7a4538 100644
+index d63b02f5..a7a4538a 100644
 --- a/dma.c
 +++ b/dma.c
 @@ -380,11 +380,28 @@ mt76_dma_get_buf(struct mt76_dev *dev, struct mt76_queue *q, int idx,
diff --git a/recipes-wifi/linux-mt76/files/patches/3010-mt76-mt7915-drop-scatter-and-gather-frame.patch b/recipes-wifi/linux-mt76/files/patches/3010-mt76-mt7915-drop-scatter-and-gather-frame.patch
index de8d4df..1b985cf 100644
--- a/recipes-wifi/linux-mt76/files/patches/3010-mt76-mt7915-drop-scatter-and-gather-frame.patch
+++ b/recipes-wifi/linux-mt76/files/patches/3010-mt76-mt7915-drop-scatter-and-gather-frame.patch
@@ -1,13 +1,12 @@
-From b5a473223aa9bebafa51b5dd465cf6924871eecf Mon Sep 17 00:00:00 2001
+From b584c123edfe2965d753d4fc7e77c1ec08f147ea Mon Sep 17 00:00:00 2001
 From: Peter Chiu <chui-hao.chiu@mediatek.com>
 Date: Wed, 28 Sep 2022 18:52:54 +0800
-Subject: [PATCH 3010/3010] mt76: mt7915: drop scatter and gather frame
+Subject: [PATCH 3010/3011] mt76: mt7915: drop scatter and gather frame
 
 The scatter and gather frame may be incorrect because WED and WO may
 send frames to host driver interleaved.
 
 Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com>
-Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
 ---
  dma.c  | 9 +++++++++
  dma.h  | 1 +
@@ -15,7 +14,7 @@
  3 files changed, 11 insertions(+)
 
 diff --git a/dma.c b/dma.c
-index a7a4538..c106ae4 100644
+index a7a4538a..c106ae42 100644
 --- a/dma.c
 +++ b/dma.c
 @@ -419,6 +419,15 @@ mt76_dma_get_buf(struct mt76_dev *dev, struct mt76_queue *q, int idx,
@@ -35,7 +34,7 @@
  		buf_addr = e->dma_addr[0];
  		e->buf = NULL;
 diff --git a/dma.h b/dma.h
-index 083cbca..221fcc8 100644
+index 083cbca4..221fcc8e 100644
 --- a/dma.h
 +++ b/dma.h
 @@ -21,6 +21,7 @@
@@ -47,7 +46,7 @@
  #define MT_DMA_PPE_CPU_REASON		GENMASK(15, 11)
  #define MT_DMA_PPE_ENTRY		GENMASK(30, 16)
 diff --git a/mt76.h b/mt76.h
-index 14c58bc..e5748f2 100644
+index 8011d4ca..9b225510 100644
 --- a/mt76.h
 +++ b/mt76.h
 @@ -32,6 +32,7 @@
diff --git a/recipes-wifi/linux-mt76/files/patches/3011-mt76-HW-ATF-support-for-mt7986.patch b/recipes-wifi/linux-mt76/files/patches/3011-mt76-HW-ATF-support-for-mt7986.patch
new file mode 100644
index 0000000..d812562
--- /dev/null
+++ b/recipes-wifi/linux-mt76/files/patches/3011-mt76-HW-ATF-support-for-mt7986.patch
@@ -0,0 +1,1015 @@
+From 966aa1887615c19ceb9d7675cd46c9c550847128 Mon Sep 17 00:00:00 2001
+From: Lian Chen <lian.chen@mediatek.com>
+Date: Mon, 7 Nov 2022 14:47:44 +0800
+Subject: [PATCH 3011/3011] mt76: HW ATF support for mt7986
+
+Signed-off-by: Lian Chen <lian.chen@mediatek.com>
+---
+ mt76_connac_mcu.h    |   2 +
+ mt7915/debugfs.c     | 405 +++++++++++++++++++++++++++++++++++++++++++
+ mt7915/init.c        |  39 +++++
+ mt7915/main.c        |  16 ++
+ mt7915/mcu.c         | 165 ++++++++++++++++++
+ mt7915/mt7915.h      |  68 ++++++++
+ mt7915/mtk_debugfs.c | 133 +++++++++++++-
+ 7 files changed, 827 insertions(+), 1 deletion(-)
+ mode change 100644 => 100755 mt7915/init.c
+
+diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
+index a368b65b..2cb498f3 100644
+--- a/mt76_connac_mcu.h
++++ b/mt76_connac_mcu.h
+@@ -1122,6 +1122,7 @@ enum {
+ 	MCU_EXT_CMD_THERMAL_CTRL = 0x2c,
+ 	MCU_EXT_CMD_WTBL_UPDATE = 0x32,
+ 	MCU_EXT_CMD_SET_DRR_CTRL = 0x36,
++	MCU_EXT_CMD_SET_FEATURE_CTRL = 0x38,
+ 	MCU_EXT_CMD_SET_RDD_CTRL = 0x3a,
+ 	MCU_EXT_CMD_ATE_CTRL = 0x3d,
+ 	MCU_EXT_CMD_PROTECT_CTRL = 0x3e,
+@@ -1131,6 +1132,7 @@ enum {
+ 	MCU_EXT_CMD_MUAR_UPDATE = 0x48,
+ 	MCU_EXT_CMD_BCN_OFFLOAD = 0x49,
+ 	MCU_EXT_CMD_RX_AIRTIME_CTRL = 0x4a,
++	MCU_EXT_CMD_AT_PROC_MODULE = 0x4b,
+ 	MCU_EXT_CMD_SET_RX_PATH = 0x4e,
+ 	MCU_EXT_CMD_EFUSE_FREE_BLOCK = 0x4f,
+ 	MCU_EXT_CMD_TX_POWER_FEATURE_CTRL = 0x58,
+diff --git a/mt7915/debugfs.c b/mt7915/debugfs.c
+index 21407030..85468cd2 100644
+--- a/mt7915/debugfs.c
++++ b/mt7915/debugfs.c
+@@ -12,6 +12,10 @@
+ #define FW_BIN_LOG_MAGIC_V2	0x44d9c99a
+ #endif
+ 
++#define MAC2STR(a) (a)[0], (a)[1], (a)[2], (a)[3], (a)[4], (a)[5]
++#define MACSTR "%02x:%02x:%02x:%02x:%02x:%02x"
++
++
+ /** global debugfs **/
+ 
+ struct hw_queue_map {
+@@ -211,6 +215,406 @@ static const struct file_operations mt7915_sys_recovery_ops = {
+ 	.llseek = default_llseek,
+ };
+ 
++static ssize_t mt7915_vow_get(struct file *file, char __user *user_buf,
++                              size_t count, loff_t *ppos)
++{
++	char *buff;
++	int desc = 0;
++	ssize_t ret;
++	static const size_t bufsz = 1000;
++
++	buff = kmalloc(bufsz, GFP_KERNEL);
++	if (!buff)
++		return -ENOMEM;
++
++	desc += scnprintf(buff + desc, bufsz - desc,
++			  "======== Control =============\n"
++			  "vow_atf_en=<0/1> 0:disable, 1:enable\n"
++			  "vow_watf_en=<0/1> 0:disable, 1:enable\n"
++			  "vow_watf_quantum=<level>-<quantum> unit 256us\n"
++			  "======== Station table =============\n"
++			  "vow_sta_dwrr_quantum_id=<wlanidx>-<WMM AC>-<Qid>\n"
++			  "vow_dwrr_max_wait_time=<time> 256us\n"
++			  "======== Debug =============\n"
++			  "vow_show_en=<0/1> 0:dieable, 1:enable\n"
++			  "vow_show_sta=<STA num>\n"
++			  "show_vow_info\n"
++			  "show_vow_sta_conf=<STA num> 0:all\n");
++	ret = simple_read_from_buffer(user_buf, count, ppos, buff, desc);
++	kfree(buff);
++	return ret;
++}
++
++static int mt7915_set_vow_sta_dwrr_quantum_id(struct mt7915_dev *dev,
++                                              u32 wcid_id,
++                                              u32 ac, u32 val)
++{
++	struct mt7915_sta *msta;
++	struct mt76_wcid *wcid;
++	int ret;
++
++	wcid = rcu_dereference(dev->mt76.wcid[wcid_id]);
++	if ((!wcid) || (!wcid->sta)) {
++		dev_err(dev->mt76.dev, "%s: error station.\n", __func__);
++		return 0;
++	}
++
++	msta = container_of(wcid, struct mt7915_sta, wcid);
++
++	msta->vow_sta_cfg.dwrr_quantum[ac] = val;
++
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, msta, VOW_DRR_STA_AC0_QUA_ID + ac);
++	dev_info(dev->mt76.dev, "%s: set sta %d, ac %d, quantum id %u.\n",
++                 __func__, wcid_id, ac, val);
++
++	return ret;
++}
++
++static int mt7915_set_vow_atf_en(struct mt7915_dev *dev, u32 val)
++{
++	int ret;
++
++	dev->vow_cfg.vow_atf_en = !!val;
++	dev->vow_cfg.sta_max_wait_time = val ? 0x40 : 0x1;
++	ret = mt7915_mcu_set_vow_feature_ctrl(dev);
++        dev_info(dev->mt76.dev, "%s: set vow_atf_en %u.\n",
++                 __func__, val);
++
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++                                          VOW_DRR_AIRTIME_DEFICIT_BOUND);
++	dev_info(dev->mt76.dev, "%s: set vow_dwrr_max_wait_time %u.\n",
++                 __func__, dev->vow_cfg.sta_max_wait_time);
++
++	return ret;
++}
++
++static int mt7915_set_vow_dwrr_max_wait_time(struct mt7915_dev *dev,
++                                             u32 val)
++{
++	int ret;
++
++	dev->vow_cfg.sta_max_wait_time = val;
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++		                          VOW_DRR_AIRTIME_DEFICIT_BOUND);
++	dev_info(dev->mt76.dev, "%s: set vow_dwrr_max_wait_time %u.\n",
++		 __func__, val);
++
++	return ret;
++}
++
++static int mt7915_set_vow_watf_en(struct mt7915_dev *dev, u32 val)
++{
++	int ret;
++
++	dev->vow_cfg.vow_watf_en = !!val;
++	ret = mt7915_mcu_set_vow_feature_ctrl(dev);
++	dev_info(dev->mt76.dev, "%s: set vow_watf_en %u.\n", __func__, val);
++
++	return ret;
++}
++
++static int mt7915_set_vow_watf_quantum(struct mt7915_dev *dev,
++                                       u32 id, u32 val)
++{
++	int ret;
++
++	dev->vow_cfg.vow_sta_dwrr_quantum[id] = val;
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++				          VOW_DRR_AIRTIME_QUANTUM_L0 + id);
++	dev_info(dev->mt76.dev, "%s: set quantum id %u, val %d.\n",
++                 __func__, id, val);
++
++	return ret;
++}
++
++extern int mt7915_vow_pleinfo_read(struct mt7915_dev *dev);
++static void mt7915_show_station_tx_airtime(struct work_struct *work){
++	struct mt7915_dev *dev = container_of(work, struct mt7915_dev,
++					      vow_work.work);
++	static u32 vow_last_tx_time[MT7916_WTBL_SIZE];
++	struct ieee80211_sta *ieee80211_sta;
++	struct mt7915_sta *msta;
++	struct mt76_wcid *wcid;
++	int idx = 0;
++	int i = 0;
++	u32 addr;
++	int tx_airtime_sum = 0;
++	int tx_add_airtime = 0;
++
++	if (!dev->vow_cfg.vow_show_en)
++		return;
++
++	rcu_read_lock();
++	for (idx = 1; (idx < dev->vow_cfg.vow_show_sta) &&
++	     (idx < MT7915_WTBL_STA); idx++) {
++		if (idx >= ARRAY_SIZE(dev->mt76.wcid))
++			return;
++
++		wcid = rcu_dereference(dev->mt76.wcid[idx]);
++		if (!wcid || !wcid->sta)
++			continue;
++
++		msta = container_of(wcid, struct mt7915_sta, wcid);
++		addr = mt7915_mac_wtbl_lmac_addr(dev, idx, 20);
++		tx_airtime_sum = 0;
++
++		for (i = 0; i < IEEE80211_NUM_ACS; i++) {
++			tx_airtime_sum += mt76_rr(dev, addr);
++			addr += 8;
++		}
++		tx_add_airtime = tx_airtime_sum - vow_last_tx_time[idx];
++		vow_last_tx_time[idx] = tx_airtime_sum;
++
++		ieee80211_sta = container_of((void *)msta, struct ieee80211_sta,
++					     drv_priv);
++
++		dev_info(dev->mt76.dev, "sta%u:" MACSTR " tx -> %u)\n",
++                         idx, MAC2STR(ieee80211_sta->addr), tx_add_airtime);
++	}
++	mt7915_vow_pleinfo_read(dev);
++	ieee80211_queue_delayed_work(mt76_hw(dev), &dev->vow_work, 1 * HZ);
++	rcu_read_unlock();
++	return;
++}
++
++
++static int mt7915_set_vow_show_en(struct mt7915_dev *dev, u32 val)
++{
++	if (!!dev->vow_cfg.vow_show_en == !!val)
++		return 0;
++	dev->vow_cfg.vow_show_en = val;
++	mt7915_mcu_set_vow_feature_ctrl(dev);
++	if (dev->vow_cfg.vow_show_en) {
++		INIT_DELAYED_WORK(&dev->vow_work, mt7915_show_station_tx_airtime);
++		ieee80211_queue_delayed_work(mt76_hw(dev), &dev->vow_work, 1 * HZ);
++	}
++	else {
++		cancel_delayed_work_sync(&dev->vow_work);
++	}
++	return 0;
++}
++
++static int mt7915_set_vow_show_sta(struct mt7915_dev *dev, u32 val)
++{
++	dev->vow_cfg.vow_show_sta = val;
++	dev_info(dev->mt76.dev, "%s: show station up to %d.\n",
++		 __func__, dev->vow_cfg.vow_show_sta);
++	return 0;
++}
++static int mt7915_set_show_vow_info(struct mt7915_dev *dev)
++{
++	dev_info(dev->mt76.dev, "====== VOW Control Information ======\n");
++	dev_info(dev->mt76.dev, "ATF Enbale: %d\n",
++                 dev->vow_cfg.vow_atf_en);
++	dev_info(dev->mt76.dev, "WATF Enable: %d\n",
++                 dev->vow_cfg.vow_watf_en);
++	dev_info(dev->mt76.dev, "refill_period: %d\n",
++                 dev->vow_cfg.refill_period);
++	dev_info(dev->mt76.dev, "===== VOW Max Deficit Information =====\n");
++	dev_info(dev->mt76.dev, "VOW Max Deficit(unit 256us): %d\n",
++                 dev->vow_cfg.sta_max_wait_time);
++	dev_info(dev->mt76.dev, "===== VOW Quantum Information =====\n");
++	dev_info(dev->mt76.dev, "Quantum ID 0 value(unit 256us): %d\n",
++                 dev->vow_cfg.vow_sta_dwrr_quantum[0]);
++	dev_info(dev->mt76.dev, "Quantum ID 1 value(unit 256us): %d\n",
++                 dev->vow_cfg.vow_sta_dwrr_quantum[1]);
++	dev_info(dev->mt76.dev, "Quantum ID 2 value(unit 256us): %d\n",
++                 dev->vow_cfg.vow_sta_dwrr_quantum[2]);
++	dev_info(dev->mt76.dev, "Quantum ID 3 value(unit 256us): %d\n",
++                 dev->vow_cfg.vow_sta_dwrr_quantum[3]);
++	return 0;
++}
++
++static int mt7915_show_vow_sta_conf(struct mt7915_dev *dev, u32 val)
++{
++	struct ieee80211_sta *ieee80211_sta;
++	struct mt7915_sta *msta;
++	struct mt76_wcid *wcid;
++	u32 i;
++	u8 q;
++
++	if (val > 0 && val < MT7915_WTBL_STA) {
++		wcid = rcu_dereference(dev->mt76.wcid[val]);
++		if (!wcid || !wcid->sta)
++			return 0;
++		msta = container_of(wcid, struct mt7915_sta, wcid);
++		ieee80211_sta = container_of((void *)msta, struct ieee80211_sta,
++					     drv_priv);
++		dev_info(dev->mt76.dev, "%s: ****** sta%d: "MACSTR"******\n",
++			 __func__, val, MAC2STR(ieee80211_sta->addr));
++		q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VO];
++		dev_info(dev->mt76.dev, "Ac0 --> %uus(%u)\n",
++			 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++		q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VI];
++		dev_info(dev->mt76.dev, "Ac1 --> %uus(%u)\n",
++			 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++		q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BE];
++		dev_info(dev->mt76.dev, "Ac2 --> %uus(%u)\n",
++			 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++		q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BK];
++		dev_info(dev->mt76.dev, "Ac3 --> %uus(%u)\n",
++			 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++	}
++	else{
++		for (i = 1; i < MT7915_WTBL_STA; i++) {
++			wcid = rcu_dereference(dev->mt76.wcid[i]);
++			if (!wcid || !wcid->sta)
++				continue;
++			msta = container_of(wcid, struct mt7915_sta, wcid);
++			ieee80211_sta = container_of((void *)msta, struct ieee80211_sta,
++						     drv_priv);
++			dev_info(dev->mt76.dev, "%s: ****** sta%d: "MACSTR"******\n",
++				 __func__, i, MAC2STR(ieee80211_sta->addr));
++			q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VO];
++			dev_info(dev->mt76.dev, "Ac0 --> %uus(%u)\n",
++				 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++			q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VI];
++			dev_info(dev->mt76.dev, "Ac1 --> %uus(%u)\n",
++				 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++			q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BE];
++			dev_info(dev->mt76.dev, "Ac2 --> %uus(%u)\n",
++				 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++			q = msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BK];
++			dev_info(dev->mt76.dev, "Ac3 --> %uus(%u)\n",
++				 (dev->vow_cfg.vow_sta_dwrr_quantum[q] << 8), q);
++		}
++	}
++	return 0;
++}
++
++static ssize_t
++mt7915_vow_set(struct file *file, const char __user *user_buf,
++		  size_t count, loff_t *ppos)
++{
++	struct mt7915_phy *phy = file->private_data;
++	struct mt7915_dev *dev = phy->dev;
++	u32 rv, param1, param2, param3;
++	char buf[128];
++	int ret = 0;
++
++	if (count >= sizeof(buf))
++		return -EINVAL;
++
++	if (copy_from_user(buf, user_buf, count))
++		return -EFAULT;
++
++	if (count && buf[count - 1] == '\n')
++		buf[count - 1] = '\0';
++	else
++		buf[count] = '\0';
++
++	if (!strncmp(buf, "vow_sta_dwrr_quantum_id",
++		strlen("vow_sta_dwrr_quantum_id")))
++	{
++		rv = sscanf(buf, "vow_sta_dwrr_quantum_id=%d-%d-%d",
++			    &param1, &param2, &param3);
++		if ((rv > 2) && (param2 < IEEE80211_NUM_ACS) &&
++                    (param3 < VOW_WATF_LEVEL_NUM)) {
++			ret = mt7915_set_vow_sta_dwrr_quantum_id(dev, param1,
++								 param2, param3);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_atf_en", strlen("vow_atf_en")))
++	{
++		rv = sscanf(buf, "vow_atf_en=%d", &param1);
++		if (rv > 0) {
++			ret = mt7915_set_vow_atf_en(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_dwrr_max_wait_time",
++		 strlen("vow_dwrr_max_wait_time")))
++	{
++		rv = sscanf(buf, "vow_dwrr_max_wait_time=%d", &param1);
++		if (rv > 0) {
++			ret = mt7915_set_vow_dwrr_max_wait_time(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_watf_en", strlen("vow_watf_en")))
++	{
++		rv = sscanf(buf, "vow_watf_en=%d", &param1);
++		if (rv > 0) {
++			ret = mt7915_set_vow_watf_en(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_watf_quantum",
++		 strlen("vow_watf_quantum")))
++	{
++		rv = sscanf(buf, "vow_watf_quantum=%d-%d",
++			    &param1, &param2);
++		if ((dev->vow_cfg.vow_watf_en) && (rv > 1) &&
++                    (param1 < VOW_WATF_LEVEL_NUM)) {
++			ret = mt7915_set_vow_watf_quantum(dev, param1, param2);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_show_en", strlen("vow_show_en")))
++	{
++		rv = sscanf(buf, "vow_show_en=%d", &param1);
++		if (rv > 0) {
++			ret = mt7915_set_vow_show_en(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "vow_show_sta", strlen("vow_show_sta")))
++	{
++		rv = sscanf(buf, "vow_show_sta=%d", &param1);
++		if ((rv > 0)&& (param1 < MT7915_WTBL_STA)) {
++			ret = mt7915_set_vow_show_sta(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "show_vow_info", strlen("show_vow_info")))
++	{
++		if (rv == 0) {
++			ret = mt7915_set_show_vow_info(dev);
++		}
++		else {
++			dev_err(dev->mt76.dev, "show_vow_info\n");
++			goto out;
++		}
++	}
++	else if (!strncmp(buf, "show_vow_sta_conf", strlen("show_vow_sta_conf")))
++	{
++		rv = sscanf(buf, "show_vow_sta_conf=%d", &param1);
++		if ((rv > 0) && (param1 < MT7915_WTBL_STA)) {
++			ret = mt7915_show_vow_sta_conf(dev, param1);
++		}
++		else {
++			goto out;
++		}
++	}
++
++	if (ret)
++		return ret;
++out:
++	return count;
++}
++
++static const struct file_operations mt7915_vow_ops = {
++	.write = mt7915_vow_set,
++	.read = mt7915_vow_get,
++	.open = simple_open,
++	.llseek = default_llseek,
++};
++
+ static int
+ mt7915_radar_trigger(void *data, u64 val)
+ {
+@@ -1107,6 +1511,7 @@ int mt7915_init_debugfs(struct mt7915_phy *phy)
+ 	debugfs_create_devm_seqfile(dev->mt76.dev, "twt_stats", dir,
+ 				    mt7915_twt_stats);
+ 	debugfs_create_file("rf_regval", 0600, dir, dev, &fops_rf_regval);
++	debugfs_create_file("vow", 0600, dir, phy, &mt7915_vow_ops);
+ 
+ 	if (!dev->dbdc_support || phy->band_idx) {
+ 		debugfs_create_u32("dfs_hw_pattern", 0400, dir,
+diff --git a/mt7915/init.c b/mt7915/init.c
+old mode 100644
+new mode 100755
+index 039a5b01..5a7fdb51
+--- a/mt7915/init.c
++++ b/mt7915/init.c
+@@ -473,10 +473,46 @@ mt7915_mac_init_band(struct mt7915_dev *dev, u8 band)
+ 	mt76_rmw(dev, MT_WTBLOFF_TOP_RSCR(band), mask, set);
+ }
+ 
++void mt7915_vow_init(struct mt7915_dev *dev)
++{
++	struct mt7915_vow_cfg *vow_cfg = &dev->vow_cfg;
++	bool ret;
++	int i;
++
++	if (!(is_mt7915(&dev->mt76)))
++		vow_cfg->vow_feature |= VOW_FEATURE_BWCG;
++
++	vow_cfg->vow_atf_en = 0x1;
++	vow_cfg->sta_max_wait_time = 0x40;
++	vow_cfg->refill_period = 0x5;
++
++	vow_cfg->vow_sta_dwrr_quantum[0] = 0x06;
++	vow_cfg->vow_sta_dwrr_quantum[1] = 0x0c;
++	vow_cfg->vow_sta_dwrr_quantum[2] = 0x10;
++	vow_cfg->vow_sta_dwrr_quantum[3] = 0x14;
++	vow_cfg->vow_sta_dwrr_quantum[4] = 0x18;
++	vow_cfg->vow_sta_dwrr_quantum[5] = 0x1c;
++	vow_cfg->vow_sta_dwrr_quantum[6] = 0x20;
++	vow_cfg->vow_sta_dwrr_quantum[7] = 0x24;
++
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++					  VOW_DRR_AIRTIME_DEFICIT_BOUND);
++	ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++					  VOW_DRR_AIRTIME_QUANTUM_ALL);
++
++	for(i = 0; i < 4; i++)
++		ret = mt7915_mcu_set_vow_drr_ctrl(dev, NULL,
++						  VOW_DRR_AIRTIME_QUANTUM_L0 + i);
++
++	ret = mt7915_mcu_set_vow_feature_ctrl(dev);
++	return;
++}
++
+ void mt7915_mac_init(struct mt7915_dev *dev)
+ {
+ 	int i;
+ 	u32 rx_len = is_mt7915(&dev->mt76) ? 0x400 : 0x680;
++	struct wiphy *wiphy = dev->phy.mt76->hw->wiphy;
+ 
+ 	/* config pse qid6 wfdma port selection */
+ 	if (!is_mt7915(&dev->mt76) && dev->hif2)
+@@ -501,6 +537,9 @@ void mt7915_mac_init(struct mt7915_dev *dev)
+ 		i = dev->mt76.led_pin ? MT_LED_GPIO_MUX3 : MT_LED_GPIO_MUX2;
+ 		mt76_rmw_field(dev, i, MT_LED_GPIO_SEL_MASK, 4);
+ 	}
++
++	if (mt7915_is_atf_defult_on(wiphy, dev))
++		mt7915_vow_init(dev);
+ }
+ 
+ int mt7915_txbf_init(struct mt7915_dev *dev)
+diff --git a/mt7915/main.c b/mt7915/main.c
+index 4ac5259d..6c910cf5 100644
+--- a/mt7915/main.c
++++ b/mt7915/main.c
+@@ -195,6 +195,7 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
+ {
+ 	struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv;
+ 	struct mt7915_dev *dev = mt7915_hw_dev(hw);
++	struct wiphy *wiphy = dev->phy.mt76->hw->wiphy;
+ 	struct mt7915_phy *phy = mt7915_hw_phy(hw);
+ 	struct mt76_txq *mtxq;
+ 	bool ext_phy = phy != &dev->phy;
+@@ -264,6 +265,10 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
+ 	mt7915_mcu_add_sta(dev, vif, NULL, true);
+ 	rcu_assign_pointer(dev->mt76.wcid[idx], &mvif->sta.wcid);
+ 
++	if (mt7915_is_atf_defult_on(wiphy, dev)) {
++		mt7915_mcu_set_vow_band(dev, mvif);
++	}
++
+ out:
+ 	mutex_unlock(&dev->mt76.mutex);
+ 
+@@ -685,6 +690,7 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+ 	struct mt7915_sta *msta = (struct mt7915_sta *)sta->drv_priv;
+ 	struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv;
+ 	bool ext_phy = mvif->phy != &dev->phy;
++	struct wiphy *wiphy = dev->phy.mt76->hw->wiphy;
+ #ifdef CONFIG_MTK_VENDOR
+ 	struct mt7915_phy *phy;
+ #endif
+@@ -739,6 +745,16 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
+ 		mt7915_mcu_set_mimo(phy, 0);
+ 	}
+ #endif
++	if (mt7915_is_atf_defult_on(wiphy, dev)) {
++		msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VO] = 2;
++		msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VI] = 2;
++		msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BE] = 1;
++		msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BK] = 0;
++		mt7915_mcu_set_vow_drr_ctrl(dev, msta, VOW_DRR_STA_BSS_GROUP);
++		mt7915_mcu_set_vow_drr_ctrl(dev, msta, VOW_DRR_STA_PAUSE_SETTING);
++		mt7915_mcu_set_vow_drr_ctrl(dev, msta, VOW_DRR_STA_ALL);
++	}
++
+ 	return 0;
+ }
+ 
+diff --git a/mt7915/mcu.c b/mt7915/mcu.c
+index ad2d6a39..4728d849 100644
+--- a/mt7915/mcu.c
++++ b/mt7915/mcu.c
+@@ -3323,6 +3323,171 @@ int mt7915_mcu_set_ser(struct mt7915_dev *dev, u8 action, u8 set, u8 band)
+ 				 &req, sizeof(req), false);
+ }
+ 
++int mt7915_mcu_set_vow_drr_ctrl(struct mt7915_dev *dev,
++                                struct mt7915_sta *msta,
++                                u32 subcmd)
++{
++	u32 setting = 0;
++	u32 i;
++
++	struct {
++		__le32 action;
++		u8 wlan_idx_lo;
++		u8 status;
++		u8 wlan_idx_hi;
++		u8 rsv0[5];
++		union {
++			__le32 com_value;
++			struct {
++				u8 air_time_quantum[VOW_MAX_STA_DWRR_NUM];
++			}air_time_quantum_all;
++		}air_time_ctrl;
++	} __packed req = {
++		.action = cpu_to_le32(subcmd),
++		.wlan_idx_lo = msta ? to_wcid_lo(msta->wcid.idx) : to_wcid_lo(0x0),
++		.wlan_idx_hi = msta ? to_wcid_hi(msta->wcid.idx) : to_wcid_hi(0x0),
++	};
++
++	switch (subcmd) {
++		case VOW_DRR_STA_ALL:{
++			setting |= 0x00;
++			setting |= msta->vif->mt76.idx;
++			setting |= msta->vow_sta_cfg.ac_change_rule << 4;
++			setting |= (msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VO] << 8);
++			setting |= (msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VI] << 12);
++			setting |= (msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BE] << 16);
++			setting |= (msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BK] << 20);
++			if (dev->vow_cfg.vow_feature & VOW_FEATURE_BWCG)
++                                setting |= ((UMAC_BWC_GROUP_MIN) << 24);
++			req.air_time_ctrl.com_value = cpu_to_le32(setting);
++			break;
++		}
++
++		case VOW_DRR_STA_BSS_GROUP:
++			req.air_time_ctrl.com_value = cpu_to_le32(0x0);
++			break;
++
++		case VOW_DRR_STA_PAUSE_SETTING:
++			req.air_time_ctrl.com_value = cpu_to_le32(msta->vow_sta_cfg.paused);
++			break;
++
++		case VOW_DRR_STA_AC0_QUA_ID:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VO]);
++			break;
++
++		case VOW_DRR_STA_AC1_QUA_ID:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_VI]);
++			break;
++
++		case VOW_DRR_STA_AC2_QUA_ID:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BE]);
++			break;
++
++		case VOW_DRR_STA_AC3_QUA_ID:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(msta->vow_sta_cfg.dwrr_quantum[IEEE80211_AC_BK]);
++			break;
++
++		case VOW_DRR_AIRTIME_DEFICIT_BOUND:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(dev->vow_cfg.sta_max_wait_time);
++			break;
++
++		case VOW_DRR_AIRTIME_QUANTUM_L0:
++		case VOW_DRR_AIRTIME_QUANTUM_L1:
++		case VOW_DRR_AIRTIME_QUANTUM_L2:
++		case VOW_DRR_AIRTIME_QUANTUM_L3:
++		case VOW_DRR_AIRTIME_QUANTUM_L4:
++		case VOW_DRR_AIRTIME_QUANTUM_L5:
++		case VOW_DRR_AIRTIME_QUANTUM_L6:
++		case VOW_DRR_AIRTIME_QUANTUM_L7:
++			req.air_time_ctrl.com_value =
++				cpu_to_le32(dev->vow_cfg.vow_sta_dwrr_quantum[subcmd -
++				            VOW_DRR_AIRTIME_QUANTUM_L0]);
++			break;
++
++		case VOW_DRR_AIRTIME_QUANTUM_ALL: {
++			for (i = 0; i < VOW_MAX_STA_DWRR_NUM; i++) {
++				req.air_time_ctrl.air_time_quantum_all.air_time_quantum[i] =
++					dev->vow_cfg.vow_sta_dwrr_quantum[i];
++			}
++			break;
++		}
++
++		default:
++			break;
++	}
++
++	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(SET_DRR_CTRL),
++				 &req, sizeof(req), false);
++}
++
++int mt7915_mcu_set_vow_feature_ctrl(struct mt7915_dev *dev)
++{
++	u16 value = 0;
++	u32 sch_value = 0;
++
++	struct vow_feature_ctrl {
++		__le16 bss_flag;
++		__le16 vow_ctrl_flag;
++		__le16 bss_value[9];
++		__le16 vow_ctrl_val;
++		__le16 time_token_value[2];
++                __le16 length_token_value[2];
++		__le32 tx_ctrl;
++		__le32 sch_ctrl;
++	} __packed req = {
++		.bss_flag = cpu_to_le16(0xffff),
++		.vow_ctrl_flag = cpu_to_le16(0xf231),
++		.bss_value[0] = cpu_to_le16(0xffff),
++		.bss_value[2] = cpu_to_le16(0xffff),
++		.bss_value[8] = cpu_to_le16(0xffff),
++		.time_token_value[0] = cpu_to_le16(0xffff),
++	};
++
++	value |= dev->vow_cfg.refill_period;
++	value |= 1 << 4;
++	value |= 1 << 5;
++	value |= dev->vow_cfg.vow_watf_en << 9;
++	value |= 1 << 12;
++	value |= dev->vow_cfg.vow_atf_en << 13;
++	value |= 1 << 14;
++	req.vow_ctrl_val = value;
++	if (dev->vow_cfg.vow_atf_en)
++		req.tx_ctrl = cpu_to_le32(0x6bf69e1f);
++	sch_value |= 1 << 6;
++	sch_value |= (((dev->vow_cfg.vow_show_en == 0) ? 0 :
++                      (dev->vow_cfg.vow_show_en - 1 )) << 4);
++	req.sch_ctrl = sch_value;
++
++	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(SET_FEATURE_CTRL),
++							 &req, sizeof(req), false);
++}
++
++int mt7915_mcu_set_vow_band(struct mt7915_dev *dev, struct mt7915_vif *mvif)
++{
++	struct module_ctrl {
++		__le16 action;
++		__le16 sub_action;
++		__le32 rsv1[5];
++		u8 rsv2[72];
++		u8 group_idx;
++		u8 band_idx;
++		u8 rsv3[2];
++	} __packed req = {
++		.action = cpu_to_le16(0x1),
++		.sub_action = cpu_to_le16(0x4),
++		.group_idx = mvif->mt76.band_idx * 4 + mvif->mt76.omac_idx % 4,
++		.band_idx = mvif->mt76.band_idx,
++	};
++
++	return mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD(AT_PROC_MODULE),
++				 &req, sizeof(req), false);
++}
++
+ int mt7915_mcu_set_txbf(struct mt7915_dev *dev, u8 action)
+ {
+ 	struct {
+diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
+index d93c394c..e5e861b8 100644
+--- a/mt7915/mt7915.h
++++ b/mt7915/mt7915.h
+@@ -131,6 +131,58 @@ struct mt7915_twt_flow {
+ 
+ DECLARE_EWMA(avg_signal, 10, 8)
+ 
++#define VOW_MAX_STA_DWRR_NUM    8
++#define VOW_WATF_LEVEL_NUM      4
++#define VOW_FEATURE_BWCG        BIT(3)
++#define UMAC_BWC_GROUP_MIN      40
++
++
++enum ext_cmd_vow_drr_ctrl {
++	/* Type 1 */
++	VOW_DRR_STA_ALL             	= 0x00,
++	VOW_DRR_STA_BSS_GROUP           = 0x01,
++	VOW_DRR_STA_AC0_QUA_ID      	= 0x03,
++	VOW_DRR_STA_AC1_QUA_ID      	= 0x04,
++	VOW_DRR_STA_AC2_QUA_ID      	= 0x05,
++	VOW_DRR_STA_AC3_QUA_ID      	= 0x06,
++
++	/* Type 2 */
++	VOW_DRR_AIRTIME_DEFICIT_BOUND   = 0x10,
++
++	/* Type 3 */
++	VOW_DRR_AIRTIME_QUANTUM_L0  	= 0x20,
++	VOW_DRR_AIRTIME_QUANTUM_L1  	= 0x21,
++	VOW_DRR_AIRTIME_QUANTUM_L2  	= 0x22,
++	VOW_DRR_AIRTIME_QUANTUM_L3  	= 0x23,
++	VOW_DRR_AIRTIME_QUANTUM_L4  	= 0x24,
++	VOW_DRR_AIRTIME_QUANTUM_L5  	= 0x25,
++	VOW_DRR_AIRTIME_QUANTUM_L6  	= 0x26,
++	VOW_DRR_AIRTIME_QUANTUM_L7  	= 0x27,
++	VOW_DRR_AIRTIME_QUANTUM_ALL 	= 0x28,
++	VOW_DRR_STA_PAUSE_SETTING       = 0x30,
++};
++
++struct mt7915_vow_sta_cfg{
++	u8 dwrr_quantum[IEEE80211_NUM_ACS];
++	u8 ac_change_rule;
++	bool paused;
++};
++
++struct mt7915_vow_cfg{
++	/*ATF setting */
++	u32  vow_feature;
++	bool vow_atf_en;
++	u8   refill_period;
++	u8   sta_max_wait_time;
++	u8   vow_sta_dwrr_quantum[VOW_MAX_STA_DWRR_NUM];
++	u8   vow_show_en;
++	u32  vow_show_sta;
++
++	/*WATF setting */
++	bool	vow_watf_en;
++};
++
++
+ struct mt7915_sta {
+ 	struct mt76_wcid wcid; /* must be first */
+ 
+@@ -152,6 +204,7 @@ struct mt7915_sta {
+ 		u8 flowid_mask;
+ 		struct mt7915_twt_flow flow[MT7915_MAX_STA_TWT_AGRT];
+ 	} twt;
++	struct mt7915_vow_sta_cfg vow_sta_cfg;
+ };
+ 
+ struct mt7915_vif_cap {
+@@ -466,6 +519,8 @@ struct mt7915_dev {
+ 	} dbg;
+ 	const struct mt7915_dbg_reg_desc *dbg_reg;
+ #endif
++	struct delayed_work vow_work;
++	struct mt7915_vow_cfg vow_cfg;
+ };
+ 
+ enum {
+@@ -498,6 +553,15 @@ enum mt7915_rdd_cmd {
+ 	RDD_IRQ_OFF,
+ };
+ 
++static inline bool
++mt7915_is_atf_defult_on(struct wiphy *wiphy, struct mt7915_dev *dev)
++{
++	return ((!wiphy_ext_feature_isset(wiphy,
++                NL80211_EXT_FEATURE_AIRTIME_FAIRNESS)) ||
++                mtk_wed_device_active(&dev->mt76.mmio.wed));
++}
++
++
+ static inline struct mt7915_phy *
+ mt7915_hw_phy(struct ieee80211_hw *hw)
+ {
+@@ -629,6 +693,10 @@ int mt7915_mcu_set_mac(struct mt7915_dev *dev, int band, bool enable,
+ int mt7915_mcu_set_test_param(struct mt7915_dev *dev, u8 param, bool test_mode,
+ 			      u8 en);
+ int mt7915_mcu_set_ser(struct mt7915_dev *dev, u8 action, u8 set, u8 band);
++int mt7915_mcu_set_vow_drr_ctrl(struct mt7915_dev *dev, struct mt7915_sta *msta,
++                                u32 subcmd);
++int mt7915_mcu_set_vow_feature_ctrl(struct mt7915_dev *dev);
++int mt7915_mcu_set_vow_band(struct mt7915_dev *dev, struct mt7915_vif *mvif);
+ int mt7915_mcu_set_sku_en(struct mt7915_phy *phy, bool enable);
+ int mt7915_mcu_set_txpower_sku(struct mt7915_phy *phy);
+ int mt7915_mcu_get_txpower_sku(struct mt7915_phy *phy, s8 *txpower, int len);
+diff --git a/mt7915/mtk_debugfs.c b/mt7915/mtk_debugfs.c
+index 41bd0ff1..12251d91 100644
+--- a/mt7915/mtk_debugfs.c
++++ b/mt7915/mtk_debugfs.c
+@@ -1300,7 +1300,6 @@ static EMPTY_QUEUE_INFO_T ple_txcmd_queue_empty_info[] = {
+ };
+ 
+ 
+-
+ static char* sta_ctrl_reg[] = {"ENABLE", "DISABLE", "PAUSE"};
+ static u32 chip_show_sta_acq_info(struct seq_file *s, struct mt7915_dev *dev, u32 *ple_stat,
+ 				  u32 *sta_pause, u32 *dis_sta_map,
+@@ -1454,6 +1453,138 @@ static void chip_get_sta_pause(struct mt7915_dev *dev, u32 *sta_pause)
+ 	}
+ }
+ 
++u32 vow_chip_show_sta_acq_info(struct mt7915_dev *dev, u32 *ple_stat,
++			       u32 *sta_pause, u32 *dis_sta_map,
++			       u32 dumptxd)
++{
++	int i, j;
++	u32 total_nonempty_cnt = 0;
++	u32 ac_num = 9, all_ac_num;
++	static char* sta_ctrl_reg[] = {"ENABLE", "DISABLE", "PAUSE"};
++	if (!is_mt7915(&dev->mt76))
++		ac_num = 17;
++
++	all_ac_num = ac_num * 4;
++
++	for (j = 0; j < all_ac_num; j++) { /* show AC Q info */
++		for (i = 0; i < 32; i++) {
++			if (((ple_stat[j + 1] & (0x1 << i)) >> i) == 0) {
++				u32 hfid, tfid, pktcnt, ac_n = j / ac_num, ctrl = 0;
++				u32 sta_num = i + (j % ac_num) * 32, fl_que_ctrl[3] = {0};
++				u32 wmmidx = 0;
++				struct mt7915_sta *msta;
++				struct mt76_wcid *wcid;
++				struct ieee80211_sta *sta = NULL;
++
++				wcid = rcu_dereference(dev->mt76.wcid[sta_num]);
++				sta = wcid_to_sta(wcid);
++				if (!sta) {
++					printk("ERROR!! no found STA wcid=%d\n", sta_num);
++					continue;
++				}
++				msta = container_of(wcid, struct mt7915_sta, wcid);
++				wmmidx = msta->vif->mt76.wmm_idx;
++
++				dev_info(dev->mt76.dev, "\tSTA%d AC%d: ", sta_num, ac_n);
++
++				fl_que_ctrl[0] |= MT_DBG_PLE_FL_QUE_CTRL0_EXECUTE_MASK;
++				fl_que_ctrl[0] |= (ENUM_UMAC_LMAC_PORT_2 <<
++						   MT_PLE_FL_QUE_CTRL0_Q_BUF_PID_SHFT);
++				fl_que_ctrl[0] |= (ac_n << MT_PLE_FL_QUE_CTRL0_Q_BUF_QID_SHFT);
++				fl_que_ctrl[0] |= sta_num;
++				mt76_wr(dev, MT_DBG_PLE_FL_QUE_CTRL0, fl_que_ctrl[0]);
++				fl_que_ctrl[1] = mt76_rr(dev, MT_DBG_PLE_FL_QUE_CTRL2);
++				fl_que_ctrl[2] = mt76_rr(dev, MT_DBG_PLE_FL_QUE_CTRL3);
++				hfid = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL2_Q_HEAD_FID_MASK,
++						 fl_que_ctrl[1]);
++				tfid = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL2_Q_TAIL_FID_MASK,
++						 fl_que_ctrl[1]);
++				pktcnt = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL3_Q_PKT_NUM_MASK,
++						   fl_que_ctrl[2]);
++				dev_info(dev->mt76.dev, "tail/head fid = 0x%03x/0x%03x, pkt cnt = 0x%03x",
++					 tfid, hfid, pktcnt);
++
++				if (((sta_pause[j % 6] & 0x1 << i) >> i) == 1)
++					ctrl = 2;
++
++				if (((dis_sta_map[j % 6] & 0x1 << i) >> i) == 1)
++					ctrl = 1;
++
++				dev_info(dev->mt76.dev, " ctrl = %s", sta_ctrl_reg[ctrl]);
++				dev_info(dev->mt76.dev, " (wmmidx=%d)\n", wmmidx);
++
++				total_nonempty_cnt++;
++			}
++		}
++	}
++
++	return total_nonempty_cnt;
++}
++
++int mt7915_vow_pleinfo_read(struct mt7915_dev *dev)
++{
++	u32 ple_stat[70] = {0}, pg_flow_ctrl[8] = {0};
++	u32 ple_txcmd_stat;
++	u32 sta_pause[CR_NUM_OF_AC] = {0}, dis_sta_map[CR_NUM_OF_AC] = {0};
++	int i;
++
++	chip_get_ple_acq_stat(dev, ple_stat);
++	ple_txcmd_stat = mt76_rr(dev, MT_DBG_PLE_TXCMD_Q_EMPTY);
++	pg_flow_ctrl[0] = mt76_rr(dev, MT_DBG_PLE_FREEPG_CNT);
++	pg_flow_ctrl[1] = mt76_rr(dev, MT_DBG_PLE_FREEPG_HEAD_TAIL);
++	pg_flow_ctrl[2] = mt76_rr(dev, MT_DBG_PLE_PG_HIF_GROUP);
++	pg_flow_ctrl[3] = mt76_rr(dev, MT_DBG_PLE_HIF_PG_INFO);
++	pg_flow_ctrl[4] = mt76_rr(dev, MT_DBG_PLE_PG_CPU_GROUP);
++	pg_flow_ctrl[5] = mt76_rr(dev, MT_DBG_PLE_CPU_PG_INFO);
++	pg_flow_ctrl[6] = mt76_rr(dev, MT_DBG_PLE_PG_HIF_TXCMD_GROUP);
++	pg_flow_ctrl[7] = mt76_rr(dev, MT_DBG_PLE_HIF_TXCMD_PG_INFO);
++	chip_get_dis_sta_map(dev, dis_sta_map);
++	chip_get_sta_pause(dev, sta_pause);
++
++	dev_info(dev->mt76.dev, "PLE Configuration Info:\n");
++
++	for (i = 0; i < 32; i++) {
++		if (((ple_stat[0] & (0x1 << i)) >> i) == 0) {
++			u32 hfid, tfid, pktcnt, fl_que_ctrl[3] = {0};
++
++			if (ple_queue_empty_info[i].QueueName != NULL) {
++				fl_que_ctrl[0] |= MT_DBG_PLE_FL_QUE_CTRL0_EXECUTE_MASK;
++				fl_que_ctrl[0] |= (ple_queue_empty_info[i].Portid <<
++						   MT_PLE_FL_QUE_CTRL0_Q_BUF_PID_SHFT);
++				fl_que_ctrl[0] |= (ple_queue_empty_info[i].Queueid <<
++						   MT_PLE_FL_QUE_CTRL0_Q_BUF_QID_SHFT);
++			} else
++				continue;
++
++			if (ple_queue_empty_info[i].Queueid >=
++			    ENUM_UMAC_LMAC_PLE_TX_Q_ALTX_0 &&
++		            ple_queue_empty_info[i].Queueid <=
++			    ENUM_UMAC_LMAC_PLE_TX_Q_PSMP_0)
++			    /* band0 set TGID 0, bit31 = 0 */
++			    mt76_wr(dev, MT_DBG_PLE_FL_QUE_CTRL1, 0x0);
++			else if (ple_queue_empty_info[i].Queueid >=
++				 ENUM_UMAC_LMAC_PLE_TX_Q_ALTX_1 &&
++				 ple_queue_empty_info[i].Queueid <=
++				 ENUM_UMAC_LMAC_PLE_TX_Q_PSMP_1)
++				/* band1 set TGID 1, bit31 = 1 */
++				mt76_wr(dev, MT_DBG_PLE_FL_QUE_CTRL1, 0x80000000);
++
++			mt76_wr(dev, MT_DBG_PLE_FL_QUE_CTRL0, fl_que_ctrl[0]);
++			fl_que_ctrl[1] = mt76_rr(dev, MT_DBG_PLE_FL_QUE_CTRL2);
++			fl_que_ctrl[2] = mt76_rr(dev, MT_DBG_PLE_FL_QUE_CTRL3);
++			hfid = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL2_Q_HEAD_FID_MASK,
++					 fl_que_ctrl[1]);
++			tfid = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL2_Q_TAIL_FID_MASK,
++					 fl_que_ctrl[1]);
++			pktcnt = FIELD_GET(MT_DBG_PLE_FL_QUE_CTRL3_Q_PKT_NUM_MASK,
++					   fl_que_ctrl[2]);
++		}
++	}
++
++	vow_chip_show_sta_acq_info(dev, ple_stat, sta_pause, dis_sta_map, 0);
++
++	return 0;
++}
+ static int mt7915_pleinfo_read(struct seq_file *s, void *data)
+ {
+ 	struct mt7915_dev *dev = dev_get_drvdata(s->private);
+-- 
+2.18.0
+
diff --git a/recipes-wifi/linux-mt76/files/patches/patches.inc b/recipes-wifi/linux-mt76/files/patches/patches.inc
index ee016a0..e0706a8 100644
--- a/recipes-wifi/linux-mt76/files/patches/patches.inc
+++ b/recipes-wifi/linux-mt76/files/patches/patches.inc
@@ -3,19 +3,15 @@
     file://0001-mt76-mt7915-rework-testmode-init-registers.patch \
     file://0002-mt76-mt7915-rework-rx-testmode-stats.patch \
     file://0003-mt76-mt7915-drop-undefined-action-frame.patch \
-    file://0004-mt76-connac-update-nss-calculation-in-txs.patch \
-    file://0005-mt76-mt7915-fix-mt7915_mcu_set_chan_info.patch \
     file://100-Revert-of-net-pass-the-dst-buffer-to-of_get_mac_addr.patch \
-    file://100-aggregation-definitions.patch \
     file://1001-mt76-mt7915-add-mtk-internal-debug-tools-for-mt76.patch \
     file://1002-mt76-mt7915-csi-implement-csi-support.patch \
     file://1003-mt76-mt7915-air-monitor-support.patch \
     file://1004-mt76-mt7915-add-support-for-muru_onoff-via-debugfs.patch \
     file://1005-mt76-certification-patches.patch \
-    file://1006-mt76-mt7915-add-L0.5-system-error-recovery-support.patch \
-    file://1007-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch \
-    file://1008-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch \
-    file://1009-mt76-mt7915-add-fw_version-dump.patch \
+    file://1006-mt76-mt7915-add-support-for-runtime-set-in-band-disc.patch \
+    file://1007-mt76-mt7915-add-mt76-vendor-muru-onoff-command.patch \
+    file://1008-mt76-mt7915-add-fw_version-dump.patch \
     file://1111-mt76-testmode-additional-supports.patch \
     file://1112-mt76-testmode-add-pre-cal-support.patch \
     file://1113-mt76-testmode-add-iBF-command-mode-support.patch \
@@ -44,4 +40,5 @@
     file://3008-mt76-mt7915-update-mt7916-trinfo-when-hw-path-enable.patch \
     file://3009-mt76-mt7915-find-rx-token-by-physical-address.patch \
     file://3010-mt76-mt7915-drop-scatter-and-gather-frame.patch \
+    file://3011-mt76-HW-ATF-support-for-mt7986.patch \
     "
diff --git a/recipes-wifi/linux-mt76/mt76.inc b/recipes-wifi/linux-mt76/mt76.inc
index ab52ca4..e15be16 100644
--- a/recipes-wifi/linux-mt76/mt76.inc
+++ b/recipes-wifi/linux-mt76/mt76.inc
@@ -1 +1 @@
-SRCREV ?= "72b87836d368685a093b927229209b61d8272541"
\ No newline at end of file
+SRCREV ?= "4bf2607362fc64fc4cb7d662feb736b7536c0811"
\ No newline at end of file