mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-09 23:39:18 +00:00
net: fec: remove eee_enabled/eee_active in fec_enet_get_eee()
fec_enet_get_eee() sets edata->eee_active and edata->eee_enabled from its own copy, and then calls phy_ethtool_get_eee() which in turn will call genphy_c45_ethtool_get_eee(). genphy_c45_ethtool_get_eee() will overwrite eee_enabled and eee_active with its own interpretation from the PHYs settings and negotiation result. Therefore, setting these members in fec_enet_get_eee() is redundant. Remove this, and remove the setting of fep->eee.eee_active member which becomes a write-only variable. Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Link: https://lore.kernel.org/r/E1rWbN2-002cCh-MY@rmk-PC.armlinux.org.uk Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
d0d8c54878
commit
b573cb0a55
@ -3139,8 +3139,6 @@ static int fec_enet_eee_mode_set(struct net_device *ndev, bool enable)
|
||||
}
|
||||
|
||||
p->tx_lpi_enabled = enable;
|
||||
p->eee_enabled = enable;
|
||||
p->eee_active = enable;
|
||||
|
||||
writel(sleep_cycle, fep->hwp + FEC_LPI_SLEEP);
|
||||
writel(wake_cycle, fep->hwp + FEC_LPI_WAKE);
|
||||
@ -3160,8 +3158,6 @@ fec_enet_get_eee(struct net_device *ndev, struct ethtool_keee *edata)
|
||||
if (!netif_running(ndev))
|
||||
return -ENETDOWN;
|
||||
|
||||
edata->eee_enabled = p->eee_enabled;
|
||||
edata->eee_active = p->eee_active;
|
||||
edata->tx_lpi_timer = p->tx_lpi_timer;
|
||||
edata->tx_lpi_enabled = p->tx_lpi_enabled;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user