Re: [net-next v5 1/3] dt-bindings: net: dsa: yt921x: Add Motorcomm YT921x switch support

From: Andrew Lunn
Date: Thu Aug 21 2025 - 09:59:11 EST


On Thu, Aug 21, 2025 at 08:50:18PM +0800, Yangfl wrote:
> On Thu, Aug 21, 2025 at 8:41 PM Andrew Lunn <andrew@xxxxxxx> wrote:
> >
> > > + switch@1d {
> > > + compatible = "motorcomm,yt9215";
> > > + /* default 0x1d, alternate 0x0 */
> > > + reg = <0x1d>;
> >
> > Just curious, what does alternative 0x0 mean? Does this switch have
> > only one strapping pin for address, so it either uses address 0x1d or
> > 0x0?
> >
> > Andrew
>
> Yes. I've seen this approach on other chips (offering two MDIO
> phyaddrs), so this should be a common practice.

If it only supports two addresses, you could add a constrain in the
binding that reg is [0x0, 0x1d].

Andrew