Thread (18 messages) flat view 18 messages, 6 authors, 2021-11-10

Re: [PATCH net v2] net: phy: phy_ethtool_ksettings_set: Don't discard phy_start_aneg's return

From: Bastian Germann <hidden>
Date: 2021-11-08 16:32:27

Am 08.11.21 um 17:09 schrieb Andrew Lunn:
On Mon, Nov 08, 2021 at 04:06:53PM +0100, Benedikt Spranger wrote:
quoted
On Mon, 8 Nov 2021 14:25:48 +0000
"Russell King (Oracle)" [off-list ref] wrote:
quoted
On Mon, Nov 08, 2021 at 03:18:34PM +0100, bage@linutronix.de wrote:
quoted
From: Bastian Germann <redacted>

Take the return of phy_start_aneg into account so that ethtool will
handle negotiation errors and not silently accept invalid input.
I don't think this description is accurate. If we get to call
phy_start_aneg() with invalid input, then something has already
gone wrong.
The MDI/MDIX/auto-MDIX settings are not checked before calling
phy_start_aneg(). If the PHY supports forcing MDI and auto-MDIX, but
not forcing MDIX _phy_start_aneg() returns a failure, which is silently
ignored.
Does the broadcom driver currently do this, or is this the new
functionality you are adding?

It actually seems odd that auto and MDI is supported, but not MDIX?  I
would suggest checking with Florian about that. Which particular
broadcom PHY is it?
It is BCM53125. Currently, you can set "mdix auto|off|on" which does not take any effect.
The chip will do what is its default depending on copper autonegotiation.

I am adding support for setting "mdix auto|off". I want the thing to error on "mdix on".
Where would I add that check?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help