[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20260121-dwmac_multi_irq-v2-0-3b829230d071@oss.nxp.com>
Date: Wed, 21 Jan 2026 15:23:34 +0100
From: Jan Petrous via B4 Relay <devnull+jan.petrous.oss.nxp.com@...nel.org>
To: Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Maxime Coquelin <mcoquelin.stm32@...il.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>,
Chester Lin <chester62515@...il.com>, Matthias Brugger <mbrugger@...e.com>,
Ghennadi Procopciuc <ghennadi.procopciuc@....nxp.com>,
NXP S32 Linux Team <s32@....com>, Shawn Guo <shawnguo@...nel.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Fabio Estevam <festevam@...il.com>, Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>
Cc: netdev@...r.kernel.org, linux-stm32@...md-mailman.stormreply.com,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
imx@...ts.linux.dev, devicetree@...r.kernel.org,
"Jan Petrous (OSS)" <jan.petrous@....nxp.com>
Subject: [PATCH RFC v2 0/4] Support multi-channel IRQs in stmmac platform
drivers
The stmmac core supports two interrupt modes, controlled by the
flag STMMAC_FLAG_MULTI_MSI_EN:
- When the flag is set, the driver uses multi-channel IRQ mode (Multi-IRQ).
- Otherwise, a single IRQ line is requested (aka MAC-IRQ):
static int stmmac_request_irq(struct net_device *dev)
{
/* Request the IRQ lines */
if (priv->plat->flags & STMMAC_FLAG_MULTI_MSI_EN)
ret = stmmac_request_irq_multi_msi(dev);
else
ret = stmmac_request_irq_single(dev);
}
At present, only PCI drivers (Intel and Loongson) make use of the Multi-IRQ
mode. This concept can be extended to DT-based embedded glue drivers
(dwmac-xxx.c).
This series adds support for reading per-channel IRQs from the DT node and
reuses the existing STMMAC_FLAG_MULTI_MSI_EN flag to enable multi-IRQ
operation in platform drivers.
The final decision if Multi-IRQ gets enabled remains on glue driver
to allow implementing any reguirements/limitions the focused platform
needs.
NXP S32G2/S32G3/S32R SoCs integrate the DWMAC IP with multi-channel
interrupt support. The dwmac-s32.c driver change is provided as an example of
enabling multi-IRQ mode for non-PCI drivers.
Signed-off-by: Jan Petrous (OSS) <jan.petrous@....nxp.com>
---
Changes in v2:
- Fixed incorrect buffer len for 'rx-queue-%d' property check
- Added backward compatibility to not break old settings
- Fixed DT example in yaml
- Link to v1: https://lore.kernel.org/r/20251214-dwmac_multi_irq-v1-0-36562ab0e9f7@oss.nxp.com
---
Jan Petrous (OSS) (4):
net: stmmac: platform: read channels irq
dt-bindings: net: nxp,s32-dwmac: Declare per-queue interrupts
arm64: dts: s32: set Ethernet channel irqs
stmmac: s32: enable support for Multi-IRQ mode
.../devicetree/bindings/net/nxp,s32-dwmac.yaml | 42 +++++++++++++++++++---
arch/arm64/boot/dts/freescale/s32g2.dtsi | 26 ++++++++++++--
arch/arm64/boot/dts/freescale/s32g3.dtsi | 26 ++++++++++++--
drivers/net/ethernet/stmicro/stmmac/dwmac-s32.c | 13 ++++++-
.../net/ethernet/stmicro/stmmac/stmmac_platform.c | 38 +++++++++++++++++++-
5 files changed, 132 insertions(+), 13 deletions(-)
---
base-commit: cb015814f8b6eebcbb8e46e111d108892c5e6821
change-id: 20251209-dwmac_multi_irq-9d8f60462cc1
Best regards,
--
Jan Petrous (OSS) <jan.petrous@....nxp.com>
Powered by blists - more mailing lists