Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Aleksei Sviridkin" <f@lex.la>
Cc: conor+dt@kernel.org, robh@kernel.org, devicetree@vger.kernel.org
Subject: Re: [RFC PATCH net-next 1/7] dt-bindings: net: add Airoha EN8811H PHY MCU
Date: Mon, 07 Sep 2026 17:46:03 +0000	[thread overview]
Message-ID: <20260907174604.46A0C1F00A3A@smtp.kernel.org> (raw)
In-Reply-To: <20260906174548.4106801-1-f@lex.la>

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Medium] The schema disables `reset-gpios` on the PHY node to prevent firmware erasure but fails to disable the `resets` and `reset-names` properties.
- [Medium] The strict `unevaluatedProperties: false` on the child PHY node rejects valid EN8811H-specific PHY properties.
--

commit 6002751a738ff01594839da605cd448738f78458
Author: Aleksei Sviridkin <f@lex.la>
Subject: dt-bindings: net: add Airoha EN8811H PHY MCU

This commit adds a device tree binding for the Airoha EN8811H PHY's MD32
MCU. It describes the MCU as an MDIO device that owns the reset line,
with the PHY function operating on a child bus, ensuring the PHY is only
visible when firmware is running.

> diff --git a/Documentation/devicetree/bindings/net/airoha,en8811h-mcu.yaml b/Documentation/devicetree/bindings/net/airoha,en8811h-mcu.yaml
> new file mode 100644
> index 0000000000000..7be0ab8622661
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/net/airoha,en8811h-mcu.yaml
[ ... ]
> +  mdio:
> +    $ref: mdio.yaml#
> +    description:
> +      The bus the PHY function answers on while firmware is running, at
> +      the same address this node occupies on the parent bus. Only that
> +      one address is passed through.
> +
> +    patternProperties:
> +      '^ethernet-phy@[0-9a-f]+$':
> +        type: object
> +        $ref: ethernet-phy.yaml#
> +        unevaluatedProperties: false

[Severity: Medium]
Does this strict evaluation constraint inadvertently block valid PHY-specific
properties?

By restricting the properties exclusively to those evaluated in
ethernet-phy.yaml#, the schema rejects specific properties defined in the
Airoha EN8811H PHY schema, such as rx-polarity from phy-common-props.yaml
or airoha,pnswap-rx.

Could this cause dt_binding_check to fail when a valid device tree includes
these EN8811H-specific PHY properties on the child node?

> +
> +        properties:
> +          reset-gpios: false
> +          reset-assert-us: false
> +          reset-deassert-us: false

[Severity: Medium]
The schema disables reset-gpios to prevent firmware erasure on the PHY
node, but does it also need to disable the standard resets and reset-names
properties?

If a device tree configures a hardware reset controller for the child
ethernet-phy node using the standard resets property, it will silently pass
validation. At runtime, the PHY framework might pulse this reset during
detachment, wiping the MCU's volatile firmware.

Should resets: false and reset-names: false be added here to fully close
this validation loophole?

> +
> +        description:
> +          The reset line belongs to the MCU node above. A reset described
> +          here would be pulsed by this node's own lifecycle, and that erases
> +          the firmware that created this PHY.
[ ... ]

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1788711797.git.f@lex.la?part=1

  reply	other threads:[~2026-09-07 17:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-06 17:45 [RFC PATCH net-next 0/7] net: mdio: an MDIO device driver for the Airoha EN8811H Aleksei Sviridkin
2026-09-06 17:45 ` [RFC PATCH net-next 1/7] dt-bindings: net: add Airoha EN8811H PHY MCU Aleksei Sviridkin
2026-09-07 17:46   ` sashiko-bot [this message]
2026-09-06 17:45 ` [RFC PATCH net-next 2/7] net: phy: add mdiodev_lock(), mdiodev_lock_nested() and mdiodev_unlock() Aleksei Sviridkin
2026-09-06 17:45 ` [RFC PATCH net-next 3/7] net: phy: air: type the buckpbus core on the mdio device Aleksei Sviridkin
2026-09-06 17:45 ` [RFC PATCH net-next 4/7] net: phy: air: move the EN8811H firmware download into the library Aleksei Sviridkin
2026-09-06 17:45 ` [RFC PATCH net-next 5/7] net: phy: air: skip the download when the MD32 is already running Aleksei Sviridkin
2026-09-06 17:45 ` [RFC PATCH net-next 6/7] net: mdio: add Airoha EN8811H MDIO device driver Aleksei Sviridkin
2026-09-07 17:46   ` sashiko-bot
2026-09-06 17:45 ` [RFC PATCH net-next 7/7] net: mdio: en8811h: add the nested bus Aleksei Sviridkin

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=20260907174604.46A0C1F00A3A@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=f@lex.la \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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