From: Igor Velkov <iav@iav.lv>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Maxime Chevallier <maxime.chevallier@bootlin.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Russell King <linux@armlinux.org.uk>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next] net: stmmac: mask the MAC interrupt while resume resets the MAC
Date: Fri, 2 Oct 2026 07:36:23 +0300 [thread overview]
Message-ID: <20261002043623.1304143-1-iav@iav.lv> (raw)
In-Reply-To: <47a5be82-c09f-486b-a7e3-35e6edb89ad6@lunn.ch>
On Thu, Oct 01, 2026 at 02:40:46PM +0200, Andrew Lunn wrote:
> For my understanding, it is the hardware reset which clears the mask,
> not software?
>
> If it is hardware, that is an odd hardware design.
Yes, the hardware: dwmac_dma_reset() sets SWR in DMA_BUS_MODE and the
MAC returns its registers to their reset values. On dwmac1000
GMAC_INT_MASK is a mask register, so its reset value 0 unmasks
everything; dwmac4 has an enable register (GMAC_INT_EN) instead.
A correction to the v1 text: no link change is needed. RGSMIIIS was
already pending before the reset (Helios64, SWR written from a test
script on the running board: int_status 0x1 under int_mask 0x1; after
it int_mask 0, DMA status 0x04000000). Nothing on the RGMII path reads
0xd8, which would clear it, so it stays pending from the first link
change on.
dwmac1000_core_init() rewrites the mask shortly after, from the same
resume thread. When that thread runs on the CPU that takes the MAC
interrupt, the storm starves it: with both on one CPU the storm hit
the first resume on Helios64, ROCK Pi 4A and ODROID-HC4; on different
CPUs it printed at most 3 messages per resume in 30 resumes.
v2 for net, with the description fixed and a Fixes tag:
https://lore.kernel.org/r/20261002043558.1302590-1-iav@iav.lv
--
Igor Velkov
next prev parent reply other threads:[~2026-10-02 4:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-30 19:28 [PATCH net-next] net: stmmac: mask the MAC interrupt while resume resets the MAC Igor Velkov via B4 Relay
2026-10-01 12:40 ` Andrew Lunn
2026-10-02 4:36 ` Igor Velkov [this message]
2026-10-04 14:42 ` Andrew Lunn
2026-10-04 18:28 ` Igor Velkov
2026-10-04 20:13 ` netdev-bot+sashiko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261002043623.1304143-1-iav@iav.lv \
--to=iav@iav.lv \
--cc=andrew+netdev@lunn.ch \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=maxime.chevallier@bootlin.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox