lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240123-carpool-avatar-c1e51ab3cc32@spud>
Date: Tue, 23 Jan 2024 18:37:55 +0000
From: Conor Dooley <conor@...nel.org>
To: Philippe Schenker <dev@...henker.ch>
Cc: netdev@...r.kernel.org, Paolo Abeni <pabeni@...hat.com>,
	Conor Dooley <conor+dt@...nel.org>,
	Woojung Huh <woojung.huh@...rochip.com>,
	Vladimir Oltean <olteanv@...il.com>, linux-kernel@...r.kernel.org,
	UNGLinuxDriver@...rochip.com, Marek Vasut <marex@...x.de>,
	Florian Fainelli <f.fainelli@...il.com>, devicetree@...r.kernel.org,
	Eric Dumazet <edumazet@...gle.com>,
	"David S . Miller" <davem@...emloft.net>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
	Jakub Kicinski <kuba@...nel.org>, Andrew Lunn <andrew@...n.ch>,
	Rob Herring <robh+dt@...nel.org>
Subject: Re: [PATCH net-next v1 1/2] dt-bindings: net: dsa: Add KSZ8567
 switch support

On Tue, Jan 23, 2024 at 06:30:16PM +0100, Philippe Schenker wrote:
> 
> 
> On Tue, 2024-01-23 at 17:23 +0000, Conor Dooley wrote:
> > On Tue, Jan 23, 2024 at 05:17:53PM +0100, Philippe Schenker wrote:
> > > 
> > > 
> > > On Tue, 2024-01-23 at 16:06 +0000, Conor Dooley wrote:
> > > > On Tue, Jan 23, 2024 at 02:50:13PM +0100, Philippe Schenker
> > > > wrote:
> > > > > From: Philippe Schenker <philippe.schenker@...ulsing.ch>
> > > > > 
> > > > > This commit adds the dt-binding for KSZ8567, a robust 7-port
> > > > > Ethernet switch. The KSZ8567 features two RGMII/MII/RMII
> > > > > interfaces,
> > > > > each capable of gigabit speeds, complemented by five 10/100
> > > > > Mbps
> > > > > MAC/PHYs.
> > > > > 
> > > > > Signed-off-by: Philippe Schenker
> > > > > <philippe.schenker@...ulsing.ch>
> > > > 
> > > > This device has all the same constraints as the other ones in
> > > > this
> > > > binding, why is it not compatible with any of them? If it isn't,
> > > > the
> > > > compatible should mention why it is not.
> > > 
> > > Hi Conor, Thanks for your message!
> > > 
> > > I need the compatible to make sure the correct ID of the switch is
> > > being set in the driver as well as its features.
> > 
> > Are the features of this switch such that a driver for another ksz
> > switch would not work (even in a limited capacity) with the 8567?
> > Things like the register map changing or some feature being removed
> > are
> > examples of why it may not work.
> 
> Yes the ksz dsa driver is made so that it checks the ID of the attached
> chip and refuses to work if it doesn't match. [1]

That sounds counter productive to be honest. Why does the driver not
trust that the dt is correct? I saw this recently in some IIO drivers,
but it was shot down for this sort of reason.

> It is a very similar chip and uses the same regmap as KSZ9567 but with
> lower phy-speeds on its 5 switch ports. The two upstream CPU ports are
> gigabit capable. All this information is set-up in the second patch of
> this series. [2]

That, to me, means the lack of a fallback is justified. If it were the
other way around, then a fallback sounds like it would be suitable.

> 
> I will include a description to the second series. Thanks for your
> feedback.

Okay, thanks. You can add
Acked-by: Conor Dooley <conor.dooley@...rochip.com>
when you do.

And despite the email, I have nothing to do with these switches, I am
just a sucker that signed up to review dt-bindings...

Thanks,
Conor.

> 
> Philippe
> 
> 
> [1]
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/net/dsa/microchip/ksz_common.c?h=v6.8-rc1#n3181
> [2]
> https://patchwork.kernel.org/project/netdevbpf/patch/20240123135014.614858-2-dev@pschenker.ch/
> 
> > 
> > > You mean I shall mention the reason in the commit-message, or
> > > where?
> > 
> > Yes.
> > 
> > Thanks,
> > Conor
> > 
> > > > >  Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml |
> > > > > 1 +
> > > > >  1 file changed, 1 insertion(+)
> > > > > 
> > > > > diff --git
> > > > > a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> > > > > b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> > > > > index c963dc09e8e1..52acc15ebcbf 100644
> > > > > ---
> > > > > a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> > > > > +++
> > > > > b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> > > > > @@ -31,6 +31,7 @@ properties:
> > > > >        - microchip,ksz9893
> > > > >        - microchip,ksz9563
> > > > >        - microchip,ksz8563
> > > > > +      - microchip,ksz8567
> > > > >  
> > > > >    reset-gpios:
> > > > >      description:
> > > > > -- 
> > > > > 2.34.1
> > > > > 

Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ