Re: [PATCH net v4 1/2] net: dsa: microchip: let phylink manage PHY EEE configuration on KSZ switches
From: Paolo Abeni
Date: Thu May 08 2025 - 06:31:11 EST
On 5/4/25 10:14 AM, Oleksij Rempel wrote:
> Phylink expects MAC drivers to provide LPI callbacks to properly manage
> Energy Efficient Ethernet (EEE) configuration. On KSZ switches with
> integrated PHYs, LPI is internally handled by hardware, while ports
> without integrated PHYs have no documented MAC-level LPI support.
>
> Provide dummy mac_disable_tx_lpi() and mac_enable_tx_lpi() callbacks to
> satisfy phylink requirements. Also, set default EEE capabilities during
> phylink initialization where applicable.
>
> Since phylink can now gracefully handle optional EEE configuration,
> remove the need for the MICREL_NO_EEE PHY flag.
>
> This change addresses issues caused by incomplete EEE refactoring
> introduced in commit fe0d4fd9285e ("net: phy: Keep track of EEE
> configuration"). It is not easily possible to fix all older kernels, but
> this patch ensures proper behavior on latest kernels and can be
> considered for backporting to stable kernels starting from v6.14.
>
> Fixes: fe0d4fd9285e ("net: phy: Keep track of EEE configuration")
> Signed-off-by: Oleksij Rempel <o.rempel@xxxxxxxxxxxxxx>
> Cc: stable@xxxxxxxxxxxxxxx # v6.14+
It would be great if either a phy maintainer could have a look here.
Thanks,
Paolo