From: "Marek Behún" <kabel@kernel.org>
To: "Pali Rohár" <pali@kernel.org>
Cc: Andrew Lunn <andrew@lunn.ch>,
Vivien Didelot <vivien.didelot@gmail.com>,
Florian Fainelli <f.fainelli@gmail.com>,
Vladimir Oltean <olteanv@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: phy: marvell: fix detection of PHY on Topaz switches
Date: Tue, 13 Apr 2021 01:45:45 +0200 [thread overview]
Message-ID: <20210413014545.1bb4601e@thinkpad> (raw)
In-Reply-To: <20210412163829.kp7feb3yhzymukg2@pali>
On Mon, 12 Apr 2021 18:38:29 +0200
Pali Rohár <pali@kernel.org> wrote:
> On Monday 12 April 2021 18:12:35 Andrew Lunn wrote:
> > On Mon, Apr 12, 2021 at 05:52:39PM +0200, Pali Rohár wrote:
> > > On Monday 12 April 2021 17:32:33 Andrew Lunn wrote:
> > > > > Anyway, now I'm looking at phy/marvell.c driver again and it supports
> > > > > only 88E6341 and 88E6390 families from whole 88E63xxx range.
> > > > >
> > > > > So do we need to define for now table for more than
> > > > > MV88E6XXX_FAMILY_6341 and MV88E6XXX_FAMILY_6390 entries?
> > > >
> > > > Probably not. I've no idea if the 6393 has an ID, so to be safe you
> > > > should add that. Assuming it has a family of its own.
> > >
> > > So what about just?
> > >
> > > if (reg == MII_PHYSID2 && !(val & 0x3f0)) {
> > > if (chip->info->family == MV88E6XXX_FAMILY_6341)
> > > val |= MV88E6XXX_PORT_SWITCH_ID_PROD_6341 >> 4;
> > > else if (chip->info->family == MV88E6XXX_FAMILY_6390)
> > > val |= MV88E6XXX_PORT_SWITCH_ID_PROD_6390 >> 4;
> > > }
> >
> > As i said, i expect the 6393 also has no ID. And i recently found out
> > Marvell have some automotive switches, 88Q5xxx which are actually
> > based around the same IP and could be added to this driver. They also
> > might not have an ID. I suspect this list is going to get longer, so
> > having it table driven will make that simpler, less error prone.
> >
> > Andrew
>
> Ok, I will use table but I fill it only with Topaz (6341) and Peridot
> (6390) which was there before as I do not have 6393 switch for testing.
>
> If you or anybody else has 6393 unit for testing, please extend then
> table.
6393 PHYs report PHY ID 0x002b0808, I.e. no model number.
I now realize that I did not implement this for 6393, these PHYs are
detected as
mv88e6085 ... PHY [...] driver [Generic PHY] (irq=POLL)
And it seems that this temperature sensor is different from 1510, 6341
and 6390 :) I will look into this and send a patch.
Marek
next prev parent reply other threads:[~2021-04-12 23:45 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-12 12:14 [PATCH] net: phy: marvell: fix detection of PHY on Topaz switches Pali Rohár
2021-04-12 13:15 ` Andrew Lunn
2021-04-12 13:34 ` Pali Rohár
2021-04-12 14:30 ` Andrew Lunn
2021-04-12 14:39 ` Pali Rohár
2021-04-12 14:44 ` Andrew Lunn
2021-04-12 15:01 ` Pali Rohár
2021-04-12 15:32 ` Andrew Lunn
2021-04-12 15:52 ` Pali Rohár
2021-04-12 16:12 ` Andrew Lunn
2021-04-12 16:38 ` Pali Rohár
2021-04-12 23:45 ` Marek Behún [this message]
2021-04-12 16:57 ` [PATCH v2] " Pali Rohár
2021-04-12 17:44 ` Andrew Lunn
2021-04-12 21:30 ` patchwork-bot+netdevbpf
2021-04-12 23:25 ` Marek Behún
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=20210413014545.1bb4601e@thinkpad \
--to=kabel@kernel.org \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.com \
--cc=pali@kernel.org \
--cc=vivien.didelot@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).