[][MAC80211][mt76][Implement pre-cal support in testmode]

[Description]
Add atenl and mt76-test commands for getting pre-cal data.

[Release-log]
N/A

Change-Id: Ib113465d0ce1c8e9c8d5461e6911ba26c0afde1c
Reviewed-on: https://gerrit.mediatek.inc/c/openwrt/feeds/mtk_openwrt_feeds/+/6365523
diff --git a/autobuild_mac80211_release/package/kernel/mt76/patches/3006-mt76-mt7915-add-statistic-for-HW-Rx-Path.patch b/autobuild_mac80211_release/package/kernel/mt76/patches/3006-mt76-mt7915-add-statistic-for-HW-Rx-Path.patch
index e91955f..9baee7b 100644
--- a/autobuild_mac80211_release/package/kernel/mt76/patches/3006-mt76-mt7915-add-statistic-for-HW-Rx-Path.patch
+++ b/autobuild_mac80211_release/package/kernel/mt76/patches/3006-mt76-mt7915-add-statistic-for-HW-Rx-Path.patch
@@ -1,7 +1,7 @@
-From 12b7c7a035359298fc7d14ae3a6dbc16ec0b70ad Mon Sep 17 00:00:00 2001
+From e5b46e9dcb0b86b87cbc61e3cc13d3c6e81c8b72 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] mt76: mt7915: add statistic for H/W Rx Path
+Subject: [PATCH 3006/3006] mt76: mt7915: add statistic for H/W Rx Path
 
 Change-Id: Id94d663f08e91c83d296bd57e5e9b65a505ae1c7
 ---
@@ -16,10 +16,10 @@
  8 files changed, 108 insertions(+), 1 deletion(-)
 
 diff --git a/mt76.h b/mt76.h
-index a65e7a3..e56fd58 100644
+index c6f3ef7..d29bcdf 100644
 --- a/mt76.h
 +++ b/mt76.h
-@@ -289,6 +289,10 @@ struct mt76_sta_stats {
+@@ -297,6 +297,10 @@ struct mt76_sta_stats {
  	u32 tx_packets;
  	u32 tx_retries;
  	u32 tx_failed;
@@ -31,10 +31,10 @@
  
  struct mt76_wcid {
 diff --git a/mt76_connac.h b/mt76_connac.h
-index 8f78d12..41d6525 100644
+index 4a43838..e324c79 100644
 --- a/mt76_connac.h
 +++ b/mt76_connac.h
-@@ -218,6 +218,11 @@ static inline bool is_mt76_fw_txp(struct mt76_dev *dev)
+@@ -224,6 +224,11 @@ static inline bool is_mt76_fw_txp(struct mt76_dev *dev)
  	}
  }
  
@@ -47,10 +47,10 @@
  {
  	static const u8 width_to_bw[] = {
 diff --git a/mt76_connac_mcu.h b/mt76_connac_mcu.h
-index ca68172..722e859 100644
+index 2162a4a..339f324 100644
 --- a/mt76_connac_mcu.h
 +++ b/mt76_connac_mcu.h
-@@ -1200,6 +1200,41 @@ enum {
+@@ -1201,6 +1201,41 @@ enum {
  	MCU_CE_CMD_GET_TXPWR = 0xd0,
  };
  
@@ -93,10 +93,10 @@
  	PATCH_SEM_RELEASE,
  	PATCH_SEM_GET
 diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 5ee9bb2..9ce5a60 100644
+index 63c702e..516717c 100644
 --- a/mt7915/mac.c
 +++ b/mt7915/mac.c
-@@ -938,6 +938,31 @@ void mt7915_wed_trigger_ser(struct mtk_wed_device *wed)
+@@ -940,6 +940,31 @@ void mt7915_wed_trigger_ser(struct mtk_wed_device *wed)
  	return;
  }
  
@@ -128,7 +128,7 @@
  static void
  mt7915_tx_check_aggr(struct ieee80211_sta *sta, __le32 *txwi)
  {
-@@ -1173,6 +1198,7 @@ static void mt7915_mac_add_txs(struct mt7915_dev *dev, void *data)
+@@ -1175,6 +1200,7 @@ static void mt7915_mac_add_txs(struct mt7915_dev *dev, void *data)
  					  &msta->wcid.stats);
  	else
  		mt76_connac2_mac_add_txs_skb(&dev->mt76, wcid, pid, txs_data);
@@ -137,7 +137,7 @@
  		goto out;
  
 diff --git a/mt7915/main.c b/mt7915/main.c
-index 7935774..a73c488 100644
+index b7c6cf6..f8da685 100644
 --- a/mt7915/main.c
 +++ b/mt7915/main.c
 @@ -1028,7 +1028,8 @@ static void mt7915_sta_statistics(struct ieee80211_hw *hw,
@@ -164,7 +164,7 @@
  }
  
 diff --git a/mt7915/mcu.c b/mt7915/mcu.c
-index 1272bee..8536b1e 100644
+index adbb107..8449ed2 100644
 --- a/mt7915/mcu.c
 +++ b/mt7915/mcu.c
 @@ -293,6 +293,27 @@ int mt7915_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a3)
@@ -196,7 +196,7 @@
  mt7915_mcu_csa_finish(void *priv, u8 *mac, struct ieee80211_vif *vif)
  {
 diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index f8dd553..bd80315 100644
+index bb2d1c4..c4bdf7f 100644
 --- a/mt7915/mmio.c
 +++ b/mt7915/mmio.c
 @@ -9,6 +9,7 @@
@@ -227,10 +227,10 @@
  #else
  	return 0;
 diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index b4d6b55..c02cc87 100644
+index 570ecc4..8c71b31 100644
 --- a/mt7915/mt7915.h
 +++ b/mt7915/mt7915.h
-@@ -546,6 +546,8 @@ u32 mt7915_wed_init_rx_buf(struct mtk_wed_device *wed,
+@@ -550,6 +550,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);
@@ -239,7 +239,7 @@
  int mt7915_register_device(struct mt7915_dev *dev);
  void mt7915_unregister_device(struct mt7915_dev *dev);
  int mt7915_eeprom_init(struct mt7915_dev *dev);
-@@ -630,6 +632,7 @@ int mt7915_mcu_rdd_background_enable(struct mt7915_phy *phy,
+@@ -634,6 +636,7 @@ int mt7915_mcu_rdd_background_enable(struct mt7915_phy *phy,
  				     struct cfg80211_chan_def *chandef);
  int mt7915_mcu_rf_regval(struct mt7915_dev *dev, u32 regidx, u32 *val, bool set);
  int mt7915_mcu_wa_cmd(struct mt7915_dev *dev, int cmd, u32 a1, u32 a2, u32 a3);
@@ -248,5 +248,5 @@
  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);
 -- 
-2.32.0
+2.18.0