From: Maxime Chevallier <maxime.chevallier@bootlin.com>
To: Oleksij Rempel <o.rempel@pengutronix.de>
Cc: Andrew Lunn <andrew@lunn.ch>,
Heiner Kallweit <hkallweit1@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Andre Edich <andre.edich@microchip.com>,
kernel@pengutronix.de, linux-kernel@vger.kernel.org,
Russell King <linux@armlinux.org.uk>,
netdev@vger.kernel.org, Lukas Wunner <lukas@wunner.de>
Subject: Re: [PATCH net v2 1/3] net: phy: smsc: Fix Auto-MDIX configuration when disabled by strap
Date: Fri, 4 Jul 2025 09:53:56 +0200 [thread overview]
Message-ID: <20250704095356.680bd24b@fedora.home> (raw)
In-Reply-To: <20250703114941.3243890-2-o.rempel@pengutronix.de>
Hi Oleksij,
On Thu, 3 Jul 2025 13:49:39 +0200
Oleksij Rempel <o.rempel@pengutronix.de> wrote:
> Correct the Auto-MDIX configuration to ensure userspace settings are
> respected when the feature is disabled by the AUTOMDIX_EN hardware strap.
>
> The LAN9500 PHY allows its default MDI-X mode to be configured via a
> hardware strap. If this strap sets the default to "MDI-X off", the
> driver was previously unable to enable Auto-MDIX from userspace.
>
> When handling the ETH_TP_MDI_AUTO case, the driver would set the
> SPECIAL_CTRL_STS_AMDIX_ENABLE_ bit but neglected to set the required
> SPECIAL_CTRL_STS_OVRRD_AMDIX_ bit. Without the override flag, the PHY
> falls back to its hardware strap default, ignoring the software request.
>
> This patch corrects the behavior by also setting the override bit when
> enabling Auto-MDIX. This ensures that the userspace configuration takes
> precedence over the hardware strap, allowing Auto-MDIX to be enabled
> correctly in all scenarios.
>
> Fixes: 05b35e7eb9a1 ("smsc95xx: add phylib support")
> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
> Cc: Andre Edich <andre.edich@microchip.com>
Reviewed-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
Maxime
next prev parent reply other threads:[~2025-07-04 7:54 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-03 11:49 [PATCH net v2 0/4] net: phy: smsc: robustness fixes for LAN87xx/LAN9500 Oleksij Rempel
2025-07-03 11:49 ` [PATCH net v2 1/3] net: phy: smsc: Fix Auto-MDIX configuration when disabled by strap Oleksij Rempel
2025-07-04 7:53 ` Maxime Chevallier [this message]
2025-07-03 11:49 ` [PATCH net v2 2/3] net: phy: smsc: Force predictable MDI-X state on LAN87xx Oleksij Rempel
2025-07-04 8:00 ` Maxime Chevallier
2025-07-04 8:16 ` Andrew Lunn
2025-07-03 11:49 ` [PATCH net v2 3/3] net: phy: smsc: Fix link failure in forced mode with Auto-MDIX Oleksij Rempel
2025-07-04 8:23 ` Andrew Lunn
2025-07-09 1:30 ` [PATCH net v2 0/4] net: phy: smsc: robustness fixes for LAN87xx/LAN9500 patchwork-bot+netdevbpf
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=20250704095356.680bd24b@fedora.home \
--to=maxime.chevallier@bootlin.com \
--cc=andre.edich@microchip.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=kernel@pengutronix.de \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=lukas@wunner.de \
--cc=netdev@vger.kernel.org \
--cc=o.rempel@pengutronix.de \
--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