netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net v2 0/2] Fix 'ethtool --show-eee' during initial stage
@ 2024-11-15 11:11 Choong Yong Liang
  2024-11-15 11:11 ` [PATCH net v2 1/2] net: phy: replace phydev->eee_enabled with eee_cfg.eee_enabled Choong Yong Liang
                   ` (2 more replies)
  0 siblings, 3 replies; 15+ messages in thread
From: Choong Yong Liang @ 2024-11-15 11:11 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit, Russell King, David S . Miller,
	Eric Dumazet, Jakub Kicinski, Paolo Abeni, Alexandre Torgue,
	Jose Abreu, Maxime Coquelin, Oleksij Rempel
  Cc: netdev, linux-kernel, linux-stm32, linux-arm-kernel

From: Choong Yong Liang <yong.liang.choong@intel.com>

When the MAC boots up with a Marvell PHY and phy_support_eee() is implemented,
the 'ethtool --show-eee' command shows that EEE is enabled, but in actuality,
the driver side is disabled. If we try to enable EEE through
'ethtool --set-eee' for a Marvell PHY, nothing happens because the eee_cfg
matches the setting required to enable EEE in ethnl_set_eee().

This patch series will remove phydev->eee_enabled and replace it with
eee_cfg.eee_enabled. When performing genphy_c45_an_config_eee_aneg(), it
will follow the master configuration to have software and hardware in sync,
allowing 'ethtool --show-eee' to display the correct value during the
initial stage.

v2 changes:
 - Implement the prototype suggested by Russell
 - Check EEE before calling phy_support_eee()

Thanks to Russell for the proposed prototype in [1].

Reference:
[1] https://patchwork.kernel.org/comment/26121323/

Choong Yong Liang (2):
  net: phy: replace phydev->eee_enabled with eee_cfg.eee_enabled
  net: stmmac: set initial EEE policy configuration

 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |  3 +++
 drivers/net/phy/phy-c45.c                         | 11 +++++------
 drivers/net/phy/phy_device.c                      |  6 +++---
 include/linux/phy.h                               |  5 ++---
 4 files changed, 13 insertions(+), 12 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2024-11-20 11:41 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-15 11:11 [PATCH net v2 0/2] Fix 'ethtool --show-eee' during initial stage Choong Yong Liang
2024-11-15 11:11 ` [PATCH net v2 1/2] net: phy: replace phydev->eee_enabled with eee_cfg.eee_enabled Choong Yong Liang
2024-11-15 13:37   ` Russell King (Oracle)
2024-11-19  9:06     ` Choong Yong Liang
2024-11-19  9:47       ` Oleksij Rempel
2024-11-20 10:48         ` Choong Yong Liang
2024-11-20 11:41         ` Russell King (Oracle)
2024-11-15 11:11 ` [PATCH net v2 2/2] net: stmmac: set initial EEE policy configuration Choong Yong Liang
2024-11-15 13:41 ` [PATCH net v2 0/2] Fix 'ethtool --show-eee' during initial stage Heiner Kallweit
2024-11-15 14:12   ` Russell King (Oracle)
2024-11-15 20:35     ` Heiner Kallweit
2024-11-16 15:34       ` Russell King (Oracle)
2024-11-16 17:41         ` Heiner Kallweit
2024-11-16 17:44           ` Russell King (Oracle)
2024-11-16 18:06             ` Heiner Kallweit

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).