mirror of
https://github.com/torvalds/linux.git
synced 2026-06-02 19:43:40 +02:00
net: stmmac: correct priv->eee_sw_timer_en setting
If we are disabling EEE/LPI, then we should not be enabling software mode. The only time when we should is if EEE is active, and we are wanting to use software-timed EEE mode. Therefore, in the disable path of stmmac_eee_init(), ensure that priv->eee_sw_timer_en is set false as we are going to be calling del_timer_sync() on the timer. This will allow us to simplify some fast-path tests in later patches. Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Link: https://patch.msgid.link/E1tXIt7-000MB0-0W@rmk-PC.armlinux.org.uk Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
900782a029
commit
4fe09a0d64
|
|
@ -478,7 +478,7 @@ static void stmmac_eee_init(struct stmmac_priv *priv, bool active)
|
|||
if (!priv->eee_active) {
|
||||
if (priv->eee_enabled) {
|
||||
netdev_dbg(priv->dev, "disable EEE\n");
|
||||
priv->eee_sw_timer_en = true;
|
||||
priv->eee_sw_timer_en = false;
|
||||
stmmac_disable_hw_lpi_timer(priv);
|
||||
del_timer_sync(&priv->eee_ctrl_timer);
|
||||
stmmac_set_eee_timer(priv, priv->hw, 0,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user