Re: [PATCH] dt-bindings: net: nvidia,tegra234-mgbe: Add missing properties

Thierry Reding <[email protected]>
Newsgroups org.kernel.vger.linux-tegra,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel,org.kernel.vger.netdev
Message-ID <aoL36TMH4HBZhLwh@orome>
On Fri, Jul 17, 2026 at 04:27:19PM -0500, Rob Herring wrote:
> On Thu, Jul 16, 2026 at 11:20:01PM +0200, Thierry Reding wrote:
> > From: Thierry Reding <[email protected]>
> > 
> > Being a DWMAC derivative, the Tegra234 MGBE supports AXI configuration
> > nodes named stmmac-axi-config and phandle references to them using the
> > snps,axi-config property.
> > 
> > While at it, add the 10gbase-r PHY mode.
> > 
> > Signed-off-by: Thierry Reding <[email protected]>
> > ---
> > This gets rid of the remaining warnings on half of the Tegra234 boards.
> > 
> >  .../devicetree/bindings/net/nvidia,tegra234-mgbe.yaml    | 9 ++++++++-
> >  1 file changed, 8 insertions(+), 1 deletion(-)
> > 
> > diff --git a/Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.yaml b/Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.yaml
> > index 215f14d1897d..dc897e312c55 100644
> > --- a/Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.yaml
> > +++ b/Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.yaml
> > @@ -81,8 +81,9 @@ properties:
> >    phy-mode:
> >      contains:
> >        enum:
> > -        - usxgmii
> >          - 10gbase-kr
> > +        - 10gbase-r
> > +        - usxgmii
> >  
> >    mdio:
> >      $ref: mdio.yaml#
> > @@ -90,6 +91,12 @@ properties:
> >      description:
> >        Optional node for embedded MDIO controller.
> >  
> > +  snps,axi-config:
> > +    $ref: snps,dwmac.yaml#/properties/snps,axi-config
> > +
> > +  stmmac-axi-config:
> > +    $ref: snps,dwmac.yaml#/properties/stmmac-axi-config
> 
> You should be referencing the whole snps,dwmac.yaml.

I initially tried that, but it makes things a lot worse:

    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): clock-names: ['mgbe', 'mac', 'mac-divider', 'ptp_ref', 'rx-input-m', 'rx-input', 'tx', 'eee-pcs', 'rx-pcs-input', 'rx-pcs-m', 'rx-pcs', 'tx-pcs'] is too long
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): clocks: [[4294967295, 380], [4294967295, 377], [4294967295, 376], [4294967295, 381], [4294967295, 357], [4294967295, 248], [4294967295, 374], [4294967295, 379], [4294967295, 369], [4294967295, 361], [4294967295, 373], [4294967295, 375]] is too long
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): compatible: ['nvidia,tegra234-mgbe'] does not contain items matching the given schema
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): interrupt-names:0: 'oneOf' conditional failed, one must be fixed:
    'macirq' was expected
    'eth_wake_irq' was expected
    'eth_lpi' was expected
    'sfty' was expected
    'common' does not match '^rx-queue-[0-7]$'
    'common' does not match '^tx-queue-[0-7]$'
    'common' does not match '^ptp-pps-[0-3]$'
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): mdio: 'compatible' is a required property
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): reg: [[109051904, 65536], [109117440, 65536], [109707264, 65536]] is too long
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml
    Documentation/devicetree/bindings/net/nvidia,tegra234-mgbe.example.dtb: ethernet@6800000 (nvidia,tegra234-mgbe): reset-names: 'oneOf' conditional failed, one must be fixed:
    ['mac', 'pcs'] is too long
    'mac' is not one of ['stmmaceth', 'ahb']
    'stmmaceth' was expected
    'ahb' was expected
    from schema $id: http://devicetree.org/schemas/net/nvidia,tegra234-mgbe.yaml

This is because while the underlying IP is derived from the Synopsis
one, the Tegra MGBE is slightly modified and has different clock inputs,
interrupts, etc.

Or, well, I guess I don't actually know (does anyoen?) if the licensed
IP is properly represented by snps,dwmac.yaml, or if it's just a set of
values that happen to apply to some set of derived IPs.

Anyway, the easiest would probably be to just duplicate the
snps,axi-config property because it's only a phandle. stmmac-axi-config
not having a vendor prefix doesn't throw an error, so we could probably
keep it as-is.

I suppose another alternative would be to add special cases into
snps,dwmac.yaml, but I don't know if that's a great idea, it's just
going to make that very messy if everyone starts doing that.

Which do you prefer? Or is there another option that you think would be
better here?

Thanks,
Thierry
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAmqC+/YACgkQ3SOs138+
s6HC8Q/+NT1bOKELxtFaaA1pi2GJEibe/v9S0HEtanKn6/i4voLp5M3xTx25/OaM
+dsUt6UcUnwNt5Su7uBPh3wXKQ9Bi6yRTE4k3ywkQUpBDBXTkeaBVoSIlrfJ1TVv
0G/YKAT74a03XQTQ9waoWaVX+R4XPuXQYXPF50eAKAZh4jLNzsO5BrfWeitvXilb
bNnRUSXepuRt4w0JUyv80JgOiYP4LGBLyn8UAWznatvMFtI5CfjhWIEouk9BmTGC
eu28WcC89UO8glLy5BqgB6pev/1Q3wfTcK/HHFrB2LN1E9YtQX4FBHwjncWoLxOB
VhSmydS87z1fXpqkX6sKMGf2rvcFRx5kygwYi40Yn7FD6b+H97uKAAFlVpNM0bdr
HPBk4JLWlXS29/tTgYEL2dT8T4suXq6rQBqnkDS8ivWVd/ZWk+sOr9Itcq6/6aSZ
zajppvG9/lX66XuY47Xqqeiyj578PNgtFe7ie2YryN/JJl1FiUMFalB+JgNLbC7b
kQ4I11G0O6TLtGypq7OUj7OBVb8+4+s3x3l6Ax1mJL8Us8o9eXAHWQjWnTzFO9lO
tudJSNZUaLvx62Hj7XlwZ2reZmNaKRwDg/1M198yt86vTBrbwJWb03EGCl55g+Fs
LwyGyowtlfVvznQyrErUtmhmjTsxnTqy1SzKDl2HsxpXl5JpxxA=
=oc48
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.