From: Jakub Kicinski <kuba@kernel.org>
To: charles.perry@microchip.com
Cc: Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org, pabeni@redhat.com, robh@kernel.org,
krzk+dt@kernel.org, claudiu.beznea@tuxon.dev,
linux-kernel@vger.kernel.org, horms@kernel.org,
conor+dt@kernel.org, devicetree@vger.kernel.org,
davem@davemloft.net, andrew+netdev@lunn.ch, edumazet@google.com,
nicolas.ferre@microchip.com
Subject: Re: [net-next,v2,1/3] dt-bindings: net: cdns,macb: add a compatible for Microchip pic64hpsc
Date: Thu, 12 Mar 2026 18:49:43 -0700 [thread overview]
Message-ID: <20260313014943.1513621-1-kuba@kernel.org> (raw)
In-Reply-To: <20260310212202.3991199-2-charles.perry@microchip.com>
This is an AI-generated review of your patch. The human sending this
email says "Not sure about the first one but the second one looks
legit"
For local reproduction steps see https://netdev-ai.bots.linux.dev/ai-local.html
---
dt-bindings: net: cdns,macb: add a compatible for Microchip pic64hpsc
This commit adds "microchip,pic64hpsc-gem" for "PIC64-HPSC" and
"microchip,pic64hx-gem" for "PIC64HX" compatible strings. It also adds a
conditional schema check to prevent adding PHYs under the GEM node for
hardware where MDIO controllers are unconnected from physical pins.
> diff --git a/Documentation/devicetree/bindings/net/cdns,macb.yaml b/Documentation/devicetree/bindings/net/cdns,macb.yaml
> --- a/Documentation/devicetree/bindings/net/cdns,macb.yaml
> +++ b/Documentation/devicetree/bindings/net/cdns,macb.yaml
> @@ -70,6 +70,14 @@
> - microchip,sama7d65-gem # Microchip SAMA7D65 gigabit ethernet interface
> - const: microchip,sama7g5-gem # Microchip SAMA7G5 gigabit ethernet interface
>
> + - items:
> + - const: microchip,pic64hpsc-gem # Microchip PIC64-HPSC
> + - const: cdns,gem
> + - items:
> + - const: microchip,pic64hx-gem # Microchip PIC64HX
> + - const: microchip,pic64hpsc-gem # Microchip PIC64-HPSC
> + - const: cdns,gem
The fallback structure appears reversed from what was recommended in v1
review. Conor Dooley suggested that pic64hpsc should fallback to pic64hx:
- items:
- const: microchip,pic64hx-gem
- const: cdns,gem
- items:
- const: microchip,pic64hpsc-gem
- const: microchip,pic64hx-gem
- const: cdns,gem
However, the current implementation has pic64hx falling back to pic64hpsc
instead. Was this reversal intentional, or should the order match the
reviewer's recommendation?
https://lore.kernel.org/netdev/20260303-emperor-childlike-6c43d8a91753@spud/
>
> reg:
> minItems: 1
[ ... ]
> @@ -196,6 +204,17 @@
> required:
> - phys
>
> + - if:
> + properties:
> + compatible:
> + contains:
> + const: microchip,p64h-gem
> + then:
> + patternProperties:
> + "^ethernet-phy@[0-9a-f]$": false
> + properties:
> + mdio: false
The conditional check references 'microchip,p64h-gem', but the compatible
strings actually added above are 'microchip,pic64hpsc-gem' and
'microchip,pic64hx-gem'. This causes the validation rule to never trigger
for the new hardware variants.
According to the commit message, the GEM IPs within pic64hpsc have their
MDIO controllers unconnected from physical pins, and this check should
prevent adding PHYs under the GEM node. However, device trees using
'microchip,pic64hpsc-gem' or 'microchip,pic64hx-gem' with invalid
MDIO/ethernet-phy configurations will silently pass schema validation.
Should this check use 'microchip,pic64hpsc-gem' instead?
This appears to be a remnant from v1 of the patch, where 'p64h' was used
as an abbreviation. Conor Dooley requested in v1 that the full 'pic'
spelling be used instead of the shortened form, and the compatible names
were updated accordingly, but this schema check was missed.
https://lore.kernel.org/netdev/20260303-emperor-childlike-6c43d8a91753@spud/
>
> unevaluatedProperties: false
>
> examples:
--
pw-bot: cr
next prev parent reply other threads:[~2026-03-13 1:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-10 21:21 [PATCH net-next v2 0/3] Initial support for PIC64-HPSC/HX Ethernet endpoint Charles Perry
2026-03-10 21:22 ` [PATCH net-next v2 1/3] dt-bindings: net: cdns,macb: add a compatible for Microchip pic64hpsc Charles Perry
2026-03-11 18:27 ` Conor Dooley
2026-03-13 1:49 ` Jakub Kicinski [this message]
2026-03-13 12:52 ` [net-next,v2,1/3] " Charles Perry
2026-03-10 21:22 ` [PATCH net-next v2 2/3] net: macb: add safeguards for jumbo frame larger than 10240 Charles Perry
2026-03-10 21:22 ` [PATCH net-next v2 3/3] net: macb: add support for Microchip pic64hpsc ethernet endpoint Charles Perry
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=20260313014943.1513621-1-kuba@kernel.org \
--to=kuba@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=charles.perry@microchip.com \
--cc=claudiu.beznea@tuxon.dev \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=nicolas.ferre@microchip.com \
--cc=pabeni@redhat.com \
--cc=robh@kernel.org \
/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