Re: [PATCH net-next] net: phy: marvell: add support for MV88E6020 internal PHYs

From: Andrew Lunn
Date: Wed Apr 24 2024 - 11:27:21 EST


On Wed, Apr 24, 2024 at 04:57:24PM +0200, Matthias Schiffer wrote:
> On Wed, 2024-04-24 at 16:52 +0200, Andrew Lunn wrote:
> > > We currently do not override the PHY ID for this family in the DSA
> > > driver - my understanding was that this is only necessary for
> > > switches that don't provide a usable PHY ID at all. As I have no
> > > idea if this PHY ID works for the whole family or just the single
> > > switch, I went with the more specific naming here.
> >
> > The 'broken' switches have the Marvell OUI, but no module number. From
> > your description it sounds like the 6250 is the same?
> >
>
> No, the PHYs have a proper ID, 0x01410db0. The "Functional Spec" for the 88E6020 switch family gives
> us the 0x01410c00 part, but the lower 10 bits are undocumented ("reserved")

Great, Marvell breaking things in new ways :-(

It would be so much nicer if they broke things consistently.

> and I don't know if they differ for each individual switch of the
> family, as I only have a 88E6020 here.

Marvell are pretty consistent within a family. So i expect this same
ID is used for them all. However, i would use MARVELL_PHY_ID_MASK so
the lower nibble is ignored.

Please document these assumptions in the commit message.

Andrew