* [PATCH net-next v2 1/2] declance: Rate-limit DMA errors
2026-03-29 18:07 [PATCH net-next v2 0/2] declance: Improve DMA error reporting Maciej W. Rozycki
@ 2026-03-29 18:07 ` Maciej W. Rozycki
2026-03-29 18:07 ` [PATCH net-next v2 2/2] declance: Include the offending address with " Maciej W. Rozycki
2026-04-01 2:40 ` [PATCH net-next v2 0/2] declance: Improve DMA error reporting patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: Maciej W. Rozycki @ 2026-03-29 18:07 UTC (permalink / raw)
To: Andrew Lunn, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni
Cc: netdev, linux-kernel
Prevent the system from becoming unusable due to a flood of DMA error
messages.
Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
---
No change from v1.
---
drivers/net/ethernet/amd/declance.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
linux-declance-ratelimit.diff
Index: linux-macro/drivers/net/ethernet/amd/declance.c
===================================================================
--- linux-macro.orig/drivers/net/ethernet/amd/declance.c
+++ linux-macro/drivers/net/ethernet/amd/declance.c
@@ -727,7 +727,7 @@ static irqreturn_t lance_dma_merr_int(in
{
struct net_device *dev = dev_id;
- printk(KERN_ERR "%s: DMA error\n", dev->name);
+ pr_err_ratelimited("%s: DMA error\n", dev->name);
return IRQ_HANDLED;
}
^ permalink raw reply [flat|nested] 4+ messages in thread* [PATCH net-next v2 2/2] declance: Include the offending address with DMA errors
2026-03-29 18:07 [PATCH net-next v2 0/2] declance: Improve DMA error reporting Maciej W. Rozycki
2026-03-29 18:07 ` [PATCH net-next v2 1/2] declance: Rate-limit DMA errors Maciej W. Rozycki
@ 2026-03-29 18:07 ` Maciej W. Rozycki
2026-04-01 2:40 ` [PATCH net-next v2 0/2] declance: Improve DMA error reporting patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: Maciej W. Rozycki @ 2026-03-29 18:07 UTC (permalink / raw)
To: Andrew Lunn, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni
Cc: netdev, linux-kernel
The address latched in the I/O ASIC LANCE DMA Pointer Register uses the
TURBOchannel bus address encoding and therefore bits 33:29 of location
referred occupy bits 4:0, bits 28:2 are left-shifted by 3, and bits 1:0
are hardwired to zero. In reality no TURBOchannel system exceeds 1GiB
of RAM though, so the address reported will always fit in 8 hex digits.
Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
---
Changes from v1:
- s/16/8/ in the change description for the printed address width.
---
drivers/net/ethernet/amd/declance.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
linux-declance-dma-merr-addr.diff
Index: linux-macro/drivers/net/ethernet/amd/declance.c
===================================================================
--- linux-macro.orig/drivers/net/ethernet/amd/declance.c
+++ linux-macro/drivers/net/ethernet/amd/declance.c
@@ -726,8 +726,10 @@ static void lance_tx(struct net_device *
static irqreturn_t lance_dma_merr_int(int irq, void *dev_id)
{
struct net_device *dev = dev_id;
+ u64 ldp = ioasic_read(IO_REG_LANCE_DMA_P);
- pr_err_ratelimited("%s: DMA error\n", dev->name);
+ pr_err_ratelimited("%s: DMA error at %#010llx\n", dev->name,
+ (ldp & 0x1f) << 29 | (ldp & 0xffffffe0) >> 3);
return IRQ_HANDLED;
}
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH net-next v2 0/2] declance: Improve DMA error reporting
2026-03-29 18:07 [PATCH net-next v2 0/2] declance: Improve DMA error reporting Maciej W. Rozycki
2026-03-29 18:07 ` [PATCH net-next v2 1/2] declance: Rate-limit DMA errors Maciej W. Rozycki
2026-03-29 18:07 ` [PATCH net-next v2 2/2] declance: Include the offending address with " Maciej W. Rozycki
@ 2026-04-01 2:40 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-04-01 2:40 UTC (permalink / raw)
To: Maciej W. Rozycki
Cc: andrew+netdev, davem, edumazet, kuba, pabeni, netdev,
linux-kernel
Hello:
This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Sun, 29 Mar 2026 19:07:18 +0100 (BST) you wrote:
> Hi,
>
> D'oh, this v2 fixes a silly thinko in the commit description of 2/2.
>
> Inspired by a recent discussion[1] I have come up with this pair of
> small improvements to DMA error reporting with declance. Please apply.
>
> [...]
Here is the summary with links:
- [net-next,v2,1/2] declance: Rate-limit DMA errors
https://git.kernel.org/netdev/net-next/c/ee769323b1bf
- [net-next,v2,2/2] declance: Include the offending address with DMA errors
https://git.kernel.org/netdev/net-next/c/aae5efaeb8aa
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] 4+ messages in thread