Commit 4fff2d33 authored by Heiner Kallweit's avatar Heiner Kallweit Committed by David S. Miller

net: phy: remove phy_error from phy_disable_interrupts

All callers of phy_disable_interrupts() call phy_error() in the error
case. Therefore we don't need to do this within the function too.
This change also allows us to use phy_disable_interrupts() in code
holding phydev->lock (because phy_error() can take this lock).
Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4d1e46a5
...@@ -662,19 +662,10 @@ static int phy_disable_interrupts(struct phy_device *phydev) ...@@ -662,19 +662,10 @@ static int phy_disable_interrupts(struct phy_device *phydev)
/* Disable PHY interrupts */ /* Disable PHY interrupts */
err = phy_config_interrupt(phydev, PHY_INTERRUPT_DISABLED); err = phy_config_interrupt(phydev, PHY_INTERRUPT_DISABLED);
if (err) if (err)
goto phy_err; return err;
/* Clear the interrupt */ /* Clear the interrupt */
err = phy_clear_interrupt(phydev); return phy_clear_interrupt(phydev);
if (err)
goto phy_err;
return 0;
phy_err:
phy_error(phydev);
return err;
} }
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment