[][MAC80211][mt76][refactor internal patches]
[Description]
Refactor the internal patches based on the mt76 update on Oct 01, 2022.
[Release-log]
N/A
Change-Id: I1fa55cc9995a9906232a1343e8abe08d45849efc
Reviewed-on: https://gerrit.mediatek.inc/c/openwrt/feeds/mtk_openwrt_feeds/+/6591089
Build: srv_hbgsm110
diff --git a/autobuild_mac80211_release/package/kernel/mt76/patches/3005-mt76-add-ser-spport-when-wed-on.patch b/autobuild_mac80211_release/package/kernel/mt76/patches/3005-mt76-add-ser-spport-when-wed-on.patch
index cee9fe0..9118c67 100644
--- a/autobuild_mac80211_release/package/kernel/mt76/patches/3005-mt76-add-ser-spport-when-wed-on.patch
+++ b/autobuild_mac80211_release/package/kernel/mt76/patches/3005-mt76-add-ser-spport-when-wed-on.patch
@@ -1,7 +1,7 @@
-From c3c6234cc24fd9b57bb0d57b194252d533f5f012 Mon Sep 17 00:00:00 2001
+From 067df4201faff9efe5d8574ce98172262bec25e1 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/3007] mt76 add ser spport when wed on
+Subject: [PATCH 3005/3010] mt76 add ser spport when wed on
Signed-off-by: Sujuan Chen <sujuan.chen@mediatek.com>
---
@@ -15,7 +15,7 @@
7 files changed, 76 insertions(+), 15 deletions(-)
diff --git a/dma.c b/dma.c
-index 3317d2b9..fa56ccfb 100644
+index 3317d2b..fa56ccf 100644
--- a/dma.c
+++ b/dma.c
@@ -169,7 +169,7 @@ mt76_free_pending_txwi(struct mt76_dev *dev)
@@ -109,7 +109,7 @@
if (!q->rx_head)
return;
diff --git a/dma.h b/dma.h
-index 90370d12..083cbca4 100644
+index 90370d1..083cbca 100644
--- a/dma.h
+++ b/dma.h
@@ -58,5 +58,5 @@ enum mt76_mcu_evt_type {
@@ -120,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 f19433d4..9b00f53c 100644
+index 959fb24..3530d21 100644
--- a/mt76.h
+++ b/mt76.h
-@@ -1379,6 +1379,7 @@ mt76_tx_status_get_hw(struct mt76_dev *dev, struct sk_buff *skb)
+@@ -1365,6 +1365,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);
@@ -132,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 197a0169..e0a51316 100644
+index 702d629..96cad2b 100644
--- a/mt7915/dma.c
+++ b/mt7915/dma.c
-@@ -522,6 +522,7 @@ int mt7915_dma_init(struct mt7915_dev *dev, struct mt7915_phy *phy2)
+@@ -532,6 +532,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];
@@ -143,7 +143,7 @@
int i;
/* clean up hw queues */
-@@ -542,28 +543,53 @@ int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
+@@ -552,28 +553,53 @@ int mt7915_dma_reset(struct mt7915_dev *dev, bool force)
mt7915_wfsys_reset(dev);
/* disable wfdma */
@@ -203,7 +203,7 @@
}
diff --git a/mt7915/mac.c b/mt7915/mac.c
-index 4e0c3ec4..0cd9cad9 100644
+index 06268e0..544d166 100644
--- a/mt7915/mac.c
+++ b/mt7915/mac.c
@@ -916,6 +916,8 @@ void mt7915_wed_release_rx_buf(struct mtk_wed_device *wed)
@@ -234,7 +234,7 @@
static void
mt7915_tx_check_aggr(struct ieee80211_sta *sta, __le32 *txwi)
{
-@@ -1665,6 +1679,12 @@ void mt7915_mac_reset_work(struct work_struct *work)
+@@ -1679,6 +1693,12 @@ void mt7915_mac_reset_work(struct work_struct *work)
if (!(READ_ONCE(dev->reset_state) & MT_MCU_CMD_STOP_DMA))
return;
@@ -248,23 +248,23 @@
if (ext_phy)
ieee80211_stop_queues(ext_phy->hw);
diff --git a/mt7915/mmio.c b/mt7915/mmio.c
-index 6e07311d..0edea0d3 100644
+index edf99d2..11c7e94 100644
--- a/mt7915/mmio.c
+++ b/mt7915/mmio.c
-@@ -761,6 +761,8 @@ mt7915_pci_wed_init(struct mt7915_dev *dev, struct device *pdev, int *irq)
+@@ -609,6 +609,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;
+ wed->wlan.ser_trigger = mt7915_wed_trigger_ser;
+
dev->mt76.rx_token_size = wed->wlan.rx_pkt;
- if (mtk_wed_device_attach(wed) != 0)
+ if (mtk_wed_device_attach(wed))
return 0;
diff --git a/mt7915/mt7915.h b/mt7915/mt7915.h
-index 2da2ff8b..a4872451 100644
+index d96709b..1a32e82 100644
--- a/mt7915/mt7915.h
+++ b/mt7915/mt7915.h
-@@ -549,6 +549,7 @@ u32 mt7915_wed_init_buf(void *ptr, dma_addr_t phys, int token_id);
+@@ -547,6 +547,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);
@@ -273,5 +273,5 @@
void mt7915_unregister_device(struct mt7915_dev *dev);
int mt7915_eeprom_init(struct mt7915_dev *dev);
--
-2.25.1
+2.18.0