Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: netdev-bot+sashiko@kernel.org
To: jszhang@kernel.org
Cc: andrew@lunn.ch, hkallweit1@gmail.com, linux@armlinux.org.uk,
	davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
	pabeni@redhat.com, robh@kernel.org, krzk+dt@kernel.org,
	conor+dt@kernel.org, sebastian.hesselbarth@gmail.com,
	maxime.chevallier@bootlin.com, mcoquelin.stm32@gmail.com,
	alexandre.torgue@foss.st.com, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, richard.genoud@bootlin.com
Subject: Re: [PATCH net-next v5 1/2] dt-bindings: net: Add Synaptics SL2610 DWMAC
Date: Sat, 05 Dec 2026 16:03:40 +0000	[thread overview]
Message-ID: <179648662010.3146.18425277200344339589@kernel.org> (raw)
In-Reply-To: <20261204152836.31432-2-jszhang@kernel.org>

Thank you for your contribution! Sashiko AI review found 2 potential
issue(s) to consider.

Critical: 0 · High: 0 · Medium: 1 · Low: 1

If you believe none of the issues are legitimate, please reply to each
issue of Medium severity or higher and explain why the AI is wrong.
If any of them are legitimate and you plan to respin, please let patchwork
know by including "pw-bot: cr" as a separate line at the end of your reply
(one such reply per series is enough).

- [Medium] The commit message says two hardware settings are controlled
  through system-controller registers: the PHY interface mode and the…
- [Low] The new binding
  Documentation/devicetree/bindings/net/syna,sl2610-dwmac.yaml lists…

--

dt-bindings: net: Add Synaptics SL2610 DWMAC

This adds a DT binding for the Synaptics SL2610 integration of DWMAC 5.20.
It also adds the new compatible to the common snps,dwmac.yaml schema. The
commit message says the PHY interface mode and the shared MDC/MDIO routing
are controlled through system-controller registers.

> diff --git a/Documentation/devicetree/bindings/net/syna,sl2610-dwmac.yaml b/Documentation/devicetree/bindings/net/syna,sl2610-dwmac.yaml
> new file mode 100644
> index 0000000000000..226d07101e90b
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/net/syna,sl2610-dwmac.yaml
> @@ -0,0 +1,122 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/net/syna,sl2610-dwmac.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Synaptics SL2610 DesignWare Ethernet MAC
> +
> +maintainers:
> +  - Jisheng Zhang <jszhang@kernel.org>

[Severity: Low]
Should this new file get a MAINTAINERS entry too?

The "ARM/Synaptics SoC support" entry only has these patterns:

F:	arch/arm/boot/dts/synaptics/
F:	arch/arm/mach-berlin/
F:	arch/arm64/boot/dts/synaptics/

So the only entry that matches this binding is the generic networking
pattern F: Documentation/devicetree/bindings/net/. As a result,
get_maintainer.pl won't pick up the maintainer listed here.

The later patch in the series, "net: stmmac: Add glue layer for Synaptics
SL2610 SoC", also adds dwmac-syna.c without updating MAINTAINERS. Other
dwmac glue drivers, such as spacemit, starfive and thead, list the binding
and the driver in one MAINTAINERS entry.

[ ... ]

> +  syna,syscon:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    items:
> +      - items:
> +          - description: Phandle to the SL2610 system controller.
> +          - description: Offset of the Ethernet interface control register.
> +    description:
> +      Phandle and register offset used to configure the Ethernet PHY
> +      interface mode.

[Severity: Medium]
Does this property cover everything the syscon is used for? The commit
message says:

    The PHY interface mode and the routing of the shared MDC/MDIO signals
    are controlled through system-controller registers.

Only the PHY interface mode register is described here. The top-level
description covers the shared MDIO topology, but it says nothing about the
routing control.

The glue driver added later in the series uses the offset cell to identify
the MAC instance. It then writes a separate, hard-coded syscon register to
set the MDIO routing:

drivers/net/ethernet/stmicro/stmmac/dwmac-syna.c:syna_dwmac_init() {
    ...
	/* Interface-control offsets identify the hardware MAC, unlike aliases. */
	switch (dwmac->rgmii_ctl) {
	case SYNA_RGMII0_CTRL:
		mdio_sel = 0;
		break;
	case SYNA_RGMII1_CTRL:
		mdio_sel = SYNA_MDIO_MASTER_SEL;
		break;
	default:
		return dev_err_probe(dev, -EINVAL, ...);
	}
	return regmap_update_bits(dwmac->regmap, SYNA_TW_PORT_CTRL, SYNA_MDIO_MASTER_SEL, mdio_sel);
}

Should the binding say that the offset also identifies the MAC instance?
Should it also document the MDIO master select, which is BIT(4) of
SYNA_TW_PORT_CTRL at 0xa04?

The second cell has a description but no enum, so dt_binding_check accepts
any offset, not just 0xa18 or 0xa3c. With a wrong offset, the MAC with the
enabled mdio child fails probe with "Unknown Ethernet interface register".

A MAC without the mdio child skips that check. Then
syna_dwmac_set_phy_intf_sel() does a read-modify-write of CTL_PHY_INTF_SEL
(GENMASK(4, 1)) at whatever offset the DT gave.

Could the second cell be limited to an enum of the two valid offsets
before this two-cell ABI is fixed?

[ ... ]

-- 
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261204152836.31432-1-jszhang%40kernel.org


  reply	other threads:[~2026-12-05 16:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-04 15:28 [PATCH net-next v5 0/2] net: stmmac: add SL2610 ethernet support Jisheng Zhang
2026-12-04 15:28 ` [PATCH net-next v5 1/2] dt-bindings: net: Add Synaptics SL2610 DWMAC Jisheng Zhang
2026-12-05 16:03   ` netdev-bot+sashiko [this message]
2026-12-04 15:28 ` [PATCH net-next v5 2/2] net: stmmac: Add glue layer for Synaptics SL2610 SoC Jisheng Zhang
2026-12-04 17:16   ` Maxime Chevallier
2026-12-04 19:01   ` Andrew Lunn
2026-12-05 16:03   ` 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=179648662010.3146.18425277200344339589@kernel.org \
    --to=netdev-bot+sashiko@kernel.org \
    --cc=alexandre.torgue@foss.st.com \
    --cc=andrew@lunn.ch \
    --cc=conor+dt@kernel.org \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=edumazet@google.com \
    --cc=hkallweit1@gmail.com \
    --cc=jszhang@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=richard.genoud@bootlin.com \
    --cc=robh@kernel.org \
    --cc=sebastian.hesselbarth@gmail.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