From: Andrew Lunn <andrew@lunn.ch>
To: Josef Raschen <josef@raschen.org>
Cc: Arun Ramadoss <arun.ramadoss@microchip.com>,
UNGLinuxDriver@microchip.com,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: phy: microchip_t1: LAN887X: Fix device init issues.
Date: Fri, 26 Sep 2025 23:46:48 +0200 [thread overview]
Message-ID: <0737ef75-b9ac-4979-8040-a3f1a83e974e@lunn.ch> (raw)
In-Reply-To: <6ac94be0-5017-49cd-baa3-cea959fa1e0d@raschen.org>
On Fri, Sep 26, 2025 at 11:24:56PM +0200, Josef Raschen wrote:
> Hello Andrew,
>
> Thanks for your feedback.
>
> On 9/26/25 00:00, Andrew Lunn wrote:
> > On Thu, Sep 25, 2025 at 10:52:22PM +0200, Josef Raschen wrote:
> > > Currently, for a LAN8870 phy, before link up, a call to ethtool to set
> > > master-slave fails with 'operation not supported'. Reason: speed, duplex
> > > and master/slave are not properly initialized.
> > >
> > > This change sets proper initial states for speed and duplex and publishes
> > > master-slave states. A default link up for speed 1000, full duplex and
> > > slave mode then works without having to call ethtool.
> >
> > Hi Josef
> >
> > What you are missing from the commit message is an explanation why the
> > LAN8870 is special, it needs to do something no other PHY does. Is
> > there something broken with this PHY? Some register not following
> > 802.3?
> >
> > Andrew
> >
> > ---
> > pw-bot: cr
> >
>
> Special about the LAN8870 might be that it is a dual speed T1 phy.
> As most other T1 pyhs have only one possible configuration the unknown
> speed configuration was not a problem so far. But here, when
> calling link up without manually setting the speed before, it seems to
> pick speed 100 in phy_sanitize_settings(). I assume that this is not the
> desired behavior?
What speeds does the PHY say it supports?
phy_sanitize_settings() should pick the highest speed the PHY supports
as the default. So if it is picking 100, it suggests the PHY is not
reporting it supports 1000? Or phy_sanitize_settings() is broken for
1000Base-T1? Please try understand why it is picking 100.
> The second problem is that ethtool initially does not allow to set
> master-slave at all. You first have to call ethtool without the
> master-slave argument, then again with it. This is fixed by reading
> the master slave configuration from the device which seems to be missing
> in the .config_init and .config_aneg functions. I took this solution from
> net/phy/dp83tg720.c.
How does this work with a regular T4 or T2 PHY? Ideally, A T1 should
be no different. And ideally, we want a solution for all T1 PHYs,
assuming it is not something which is special for this PHY.
Andrew
next prev parent reply other threads:[~2025-09-26 21:47 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-25 20:52 Josef Raschen
2025-09-25 22:00 ` Andrew Lunn
2025-09-26 21:24 ` Josef Raschen
2025-09-26 21:46 ` Andrew Lunn [this message]
2025-09-29 19:30 ` Josef Raschen
2025-10-03 12:59 ` Divya.Koppera
2025-10-06 18:44 ` Andrew Lunn
2025-10-07 6:01 ` Divya.Koppera
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=0737ef75-b9ac-4979-8040-a3f1a83e974e@lunn.ch \
--to=andrew@lunn.ch \
--cc=UNGLinuxDriver@microchip.com \
--cc=arun.ramadoss@microchip.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=josef@raschen.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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
all inboxes | Powered by JetHome®