* [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
@ 2026-08-19 13:07 Shiji Yang
2026-08-21 10:54 ` Simon Horman
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Shiji Yang @ 2026-08-19 13:07 UTC (permalink / raw)
To: netdev
Cc: Rex Lu, Felix Fietkau, Lorenzo Bianconi, Andrew Lunn,
David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Matthias Brugger, AngeloGioacchino Del Regno, linux-kernel,
linux-arm-kernel, linux-mediatek, Shiji Yang
Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
patch was pulled from mtk-openwrt-feeds GPL open source project.
Link: https://github.com/mediatek/mtk-openwrt-feeds/commit/07c87502e854b68b48544d101b6fe17ec059b97b
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
---
drivers/net/ethernet/mediatek/mtk_wed.c | 5 +++++
drivers/net/ethernet/mediatek/mtk_wed_regs.h | 1 +
2 files changed, 6 insertions(+)
diff --git a/drivers/net/ethernet/mediatek/mtk_wed.c b/drivers/net/ethernet/mediatek/mtk_wed.c
index 10d9beaae..53d3b7e00 100644
--- a/drivers/net/ethernet/mediatek/mtk_wed.c
+++ b/drivers/net/ethernet/mediatek/mtk_wed.c
@@ -2071,6 +2071,11 @@ mtk_wed_dma_enable(struct mtk_wed_device *dev)
wdma_set(dev, MTK_WDMA_GLO_CFG, MTK_WDMA_GLO_CFG_TX_DMA_EN);
}
+ if (mtk_wed_is_v2(dev->hw))
+ wdma_m32(dev, MTK_WDMA_GLO_CFG,
+ MTK_WDMA_GLO_CFG_RESV_BUFF,
+ FIELD_PREP(MTK_WDMA_GLO_CFG_RESV_BUFF, 0x80));
+
wed_set(dev, MTK_WED_GLO_CFG,
MTK_WED_GLO_CFG_TX_DMA_EN |
MTK_WED_GLO_CFG_RX_DMA_EN);
diff --git a/drivers/net/ethernet/mediatek/mtk_wed_regs.h b/drivers/net/ethernet/mediatek/mtk_wed_regs.h
index c71190924..e5f83100d 100644
--- a/drivers/net/ethernet/mediatek/mtk_wed_regs.h
+++ b/drivers/net/ethernet/mediatek/mtk_wed_regs.h
@@ -433,6 +433,7 @@ struct mtk_wdma_desc {
#define MTK_WDMA_GLO_CFG_TX_DMA_BUSY BIT(1)
#define MTK_WDMA_GLO_CFG_RX_DMA_EN BIT(2)
#define MTK_WDMA_GLO_CFG_RX_DMA_BUSY BIT(3)
+#define MTK_WDMA_GLO_CFG_RESV_BUFF GENMASK(23, 16)
#define MTK_WDMA_GLO_CFG_RX_INFO3_PRERES BIT(26)
#define MTK_WDMA_GLO_CFG_RX_INFO2_PRERES BIT(27)
#define MTK_WDMA_GLO_CFG_RX_INFO1_PRERES BIT(28)
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-19 13:07 [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80 Shiji Yang
@ 2026-08-21 10:54 ` Simon Horman
2026-08-22 0:41 ` Jakub Kicinski
2026-08-24 18:20 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 8+ messages in thread
From: Simon Horman @ 2026-08-21 10:54 UTC (permalink / raw)
To: Shiji Yang
Cc: netdev, Rex Lu, Felix Fietkau, Lorenzo Bianconi, Andrew Lunn,
David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Matthias Brugger, AngeloGioacchino Del Regno, linux-kernel,
linux-arm-kernel, linux-mediatek
On Wed, Aug 19, 2026 at 09:07:07PM +0800, Shiji Yang wrote:
> Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> patch was pulled from mtk-openwrt-feeds GPL open source project.
>
> Link: https://github.com/mediatek/mtk-openwrt-feeds/commit/07c87502e854b68b48544d101b6fe17ec059b97b
> Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
As a bug fix for code present in the net tree, this should
1. Be targeted at the net tree
Subject: [PATCH net] ...
2. Be CCed to stable
3. Have a fixes tag. Perhaps this one?
Fixes: cf26df8833cc ("net: ethernet: mtk_eth_wed: add mtk_wed_configure_irq and mtk_wed_dma_{enable/disable}")
I'm unsure if the maintainers would like a repost because of this.
But at any rate, please keep it in mind for the future.
More information on the netdev development processes can be found here:
https://docs.kernel.org/process/maintainer-netdev.html
The above not withstanding, this looks good to me.
Reviewed-by: Simon Horman <horms@kernel.org>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-19 13:07 [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80 Shiji Yang
2026-08-21 10:54 ` Simon Horman
@ 2026-08-22 0:41 ` Jakub Kicinski
2026-08-22 8:52 ` Lorenzo Bianconi
2026-08-24 18:20 ` patchwork-bot+netdevbpf
2 siblings, 1 reply; 8+ messages in thread
From: Jakub Kicinski @ 2026-08-22 0:41 UTC (permalink / raw)
To: Lorenzo Bianconi
Cc: Shiji Yang, netdev, Rex Lu, Felix Fietkau, Andrew Lunn,
David S. Miller, Eric Dumazet, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, linux-kernel, linux-arm-kernel,
linux-mediatek
On Wed, 19 Aug 2026 21:07:07 +0800 Shiji Yang wrote:
> Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> patch was pulled from mtk-openwrt-feeds GPL open source project.
Lorenzo, could you TAL? (incl. Simon's suggestion of the Fixes tag)
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-22 0:41 ` Jakub Kicinski
@ 2026-08-22 8:52 ` Lorenzo Bianconi
2026-08-24 7:48 ` Lorenzo Bianconi
0 siblings, 1 reply; 8+ messages in thread
From: Lorenzo Bianconi @ 2026-08-22 8:52 UTC (permalink / raw)
To: Jakub Kicinski
Cc: Shiji Yang, netdev, Rex Lu, Felix Fietkau, Andrew Lunn,
David S. Miller, Eric Dumazet, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, linux-kernel, linux-arm-kernel,
linux-mediatek
[-- Attachment #1: Type: text/plain, Size: 459 bytes --]
On Aug 21, Jakub Kicinski wrote:
> On Wed, 19 Aug 2026 21:07:07 +0800 Shiji Yang wrote:
> > Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> > Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> > patch was pulled from mtk-openwrt-feeds GPL open source project.
>
> Lorenzo, could you TAL? (incl. Simon's suggestion of the Fixes tag)
sure, I am AFK now, I will review it next week.
Regards,
Lorenzo
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-22 8:52 ` Lorenzo Bianconi
@ 2026-08-24 7:48 ` Lorenzo Bianconi
2026-08-24 8:00 ` 回覆: " Rex Lu (盧建銘)
0 siblings, 1 reply; 8+ messages in thread
From: Lorenzo Bianconi @ 2026-08-24 7:48 UTC (permalink / raw)
To: Jakub Kicinski
Cc: Shiji Yang, netdev, Rex Lu, Felix Fietkau, Andrew Lunn,
David S. Miller, Eric Dumazet, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, linux-kernel, linux-arm-kernel,
linux-mediatek
[-- Attachment #1: Type: text/plain, Size: 651 bytes --]
> On Aug 21, Jakub Kicinski wrote:
> > On Wed, 19 Aug 2026 21:07:07 +0800 Shiji Yang wrote:
> > > Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> > > Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> > > patch was pulled from mtk-openwrt-feeds GPL open source project.
> >
> > Lorenzo, could you TAL? (incl. Simon's suggestion of the Fixes tag)
I am wondering if this is necessary for v3 as well.
@Rex any input on it?
Regarding Fixes tag, I think cf26df8833cc is the right one.
Regards,
Lorenzo
>
> sure, I am AFK now, I will review it next week.
>
> Regards,
> Lorenzo
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* 回覆: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-24 7:48 ` Lorenzo Bianconi
@ 2026-08-24 8:00 ` Rex Lu (盧建銘)
2026-08-24 9:05 ` Lorenzo Bianconi
0 siblings, 1 reply; 8+ messages in thread
From: Rex Lu (盧建銘) @ 2026-08-24 8:00 UTC (permalink / raw)
To: Lorenzo Bianconi, Jakub Kicinski
Cc: Shiji Yang, netdev@vger.kernel.org, Felix Fietkau, Andrew Lunn,
David S. Miller, Eric Dumazet, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org
Hi Lorenzo,
it is only for v2. v3 changed the hw design and fixed it. so this RESV_BUFF register was removed
Thanks
Rex Lu
________________________________________
寄件者: Lorenzo Bianconi
已傳送: 星期一, 2026 年 8 月 24 日 下午 03:48
收件者: Jakub Kicinski
副本: Shiji Yang; netdev@vger.kernel.org; Rex Lu (盧建銘); Felix Fietkau; Andrew Lunn; David S. Miller; Eric Dumazet; Paolo Abeni; Matthias Brugger; AngeloGioacchino Del Regno; linux-kernel@vger.kernel.org; linux-arm-kernel@lists.infradead.org; linux-mediatek@lists.infradead.org
主旨: Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
> On Aug 21, Jakub Kicinski wrote:
> > On Wed, 19 Aug 2026 21:07:07 +0800 Shiji Yang wrote:
> > > Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> > > Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> > > patch was pulled from mtk-openwrt-feeds GPL open source project.
> >
> > Lorenzo, could you TAL? (incl. Simon's suggestion of the Fixes tag)
I am wondering if this is necessary for v3 as well.
@Rex any input on it?
Regarding Fixes tag, I think cf26df8833cc is the right one.
Regards,
Lorenzo
>
> sure, I am AFK now, I will review it next week.
>
> Regards,
> Lorenzo
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: 回覆: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-24 8:00 ` 回覆: " Rex Lu (盧建銘)
@ 2026-08-24 9:05 ` Lorenzo Bianconi
0 siblings, 0 replies; 8+ messages in thread
From: Lorenzo Bianconi @ 2026-08-24 9:05 UTC (permalink / raw)
To: Rex Lu (盧建銘)
Cc: Jakub Kicinski, Shiji Yang, netdev@vger.kernel.org, Felix Fietkau,
Andrew Lunn, David S. Miller, Eric Dumazet, Paolo Abeni,
Matthias Brugger, AngeloGioacchino Del Regno,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org
[-- Attachment #1: Type: text/plain, Size: 1496 bytes --]
> Hi Lorenzo,
>
> it is only for v2. v3 changed the hw design and fixed it. so this RESV_BUFF register was removed
Hi Rex,
thx for pointing this out. In this case:
Acked-by: Lorenzo Bianconi <lorenzo@kernel.org>
>
> Thanks
> Rex Lu
> ________________________________________
> 寄件者: Lorenzo Bianconi
> 已傳送: 星期一, 2026 年 8 月 24 日 下午 03:48
> 收件者: Jakub Kicinski
> 副本: Shiji Yang; netdev@vger.kernel.org; Rex Lu (盧建銘); Felix Fietkau; Andrew Lunn; David S. Miller; Eric Dumazet; Paolo Abeni; Matthias Brugger; AngeloGioacchino Del Regno; linux-kernel@vger.kernel.org; linux-arm-kernel@lists.infradead.org; linux-mediatek@lists.infradead.org
> 主旨: Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
>
> > On Aug 21, Jakub Kicinski wrote:
> > > On Wed, 19 Aug 2026 21:07:07 +0800 Shiji Yang wrote:
> > > > Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> > > > Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> > > > patch was pulled from mtk-openwrt-feeds GPL open source project.
> > >
> > > Lorenzo, could you TAL? (incl. Simon's suggestion of the Fixes tag)
>
> I am wondering if this is necessary for v3 as well.
> @Rex any input on it?
>
> Regarding Fixes tag, I think cf26df8833cc is the right one.
>
> Regards,
> Lorenzo
>
> >
> > sure, I am AFK now, I will review it next week.
> >
> > Regards,
> > Lorenzo
>
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
2026-08-19 13:07 [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80 Shiji Yang
2026-08-21 10:54 ` Simon Horman
2026-08-22 0:41 ` Jakub Kicinski
@ 2026-08-24 18:20 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 8+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-08-24 18:20 UTC (permalink / raw)
To: Shiji Yang
Cc: netdev, rex.lu, nbd, lorenzo, andrew+netdev, davem, edumazet,
kuba, pabeni, matthias.bgg, angelogioacchino.delregno,
linux-kernel, linux-arm-kernel, linux-mediatek
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Wed, 19 Aug 2026 21:07:07 +0800 you wrote:
> Change WDMA RESV_BUFF from 0x40 to 0x80 to avoid CDM TX FIFO overflow.
> Without this patch mt7986 and mt7981 may have WDMA TX hang issue. This
> patch was pulled from mtk-openwrt-feeds GPL open source project.
>
> Link: https://github.com/mediatek/mtk-openwrt-feeds/commit/07c87502e854b68b48544d101b6fe17ec059b97b
> Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
>
> [...]
Here is the summary with links:
- net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
https://git.kernel.org/netdev/net/c/c0ef04232f9f
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2026-08-24 18:21 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-19 13:07 [PATCH] net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80 Shiji Yang
2026-08-21 10:54 ` Simon Horman
2026-08-22 0:41 ` Jakub Kicinski
2026-08-22 8:52 ` Lorenzo Bianconi
2026-08-24 7:48 ` Lorenzo Bianconi
2026-08-24 8:00 ` 回覆: " Rex Lu (盧建銘)
2026-08-24 9:05 ` Lorenzo Bianconi
2026-08-24 18:20 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox