Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 08f51385 authored by Heiner Kallweit's avatar Heiner Kallweit Committed by David S. Miller
Browse files

net: phy: fix phy_start to consider PHY_IGNORE_INTERRUPT



This condition wasn't adjusted when PHY_IGNORE_INTERRUPT (-2) was added
long ago. In case of PHY_IGNORE_INTERRUPT the MAC interrupt indicates
also PHY state changes and we should do what the symbol says.

Fixes: 84a527a4 ("net: phylib: fix interrupts re-enablement in phy_start")
Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 88c991a9
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -822,7 +822,7 @@ void phy_start(struct phy_device *phydev)
		phy_resume(phydev);

		/* make sure interrupts are re-enabled for the PHY */
		if (phydev->irq != PHY_POLL) {
		if (phy_interrupt_is_valid(phydev)) {
			err = phy_enable_interrupts(phydev);
			if (err < 0)
				break;