[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Z-RIVkVOgpzTjKZv@shell.armlinux.org.uk>
Date: Wed, 26 Mar 2025 18:32:54 +0000
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Christian Marangi <ansuelsmth@...il.com>
Cc: Andrew Lunn <andrew@...n.ch>, Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Heiner Kallweit <hkallweit1@...il.com>, netdev@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [net-next RFC PATCH v2 2/3] net: phy: Add support for Aeonsemi
AS21xxx PHYs
On Wed, Mar 26, 2025 at 07:18:12PM +0100, Christian Marangi wrote:
> On Wed, Mar 26, 2025 at 06:08:09PM +0000, Russell King (Oracle) wrote:
> > An alternative would be to change the match_phy_device() method to
> > pass the phy_driver, which would allow a single match_phy_device
> > function to match the new hardware ID values against the PHY IDs in
> > the phy_driver without needing to modify the IDs in phy_device.
> >
>
> I also considered extending the function with additional stuff but then
> I considered that would mean rework each PHY driver and destroy PHY
> driver downstream, not something we should care but still quite a big
> task. If the -ENODEV path is not OK, I feel an additional OP is better
> than tweaking match_phy_device.
For those in the kernel, 8 files, 26 initialisers.
drivers/net/phy/nxp-c45-tja11xx.c can probably be simplified with
this idea, reducing it down to a pair of functions.
drivers/net/phy/bcm87xx.c can probably be reduced to one match function.
So, doing so would appear to bring benefits to other PHY drivers.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
Powered by blists - more mailing lists