[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <5b0ec181-0b51-6e4a-ca1a-097d44c2b7e9@gmail.com>
Date: Sun, 16 Dec 2018 16:52:21 +0100
From: Heiner Kallweit <hkallweit1@...il.com>
To: Andrew Lunn <andrew@...n.ch>,
Florian Fainelli <f.fainelli@...il.com>,
David Miller <davem@...emloft.net>
Cc: "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: [PATCH net-next] net: phy: print error message in phy_error
So far phy_error() silently stops the PHY state machine. If the network
driver doesn't inform about a MDIO error then the user may wonder why
his network is down. So let's inform the user.
Signed-off-by: Heiner Kallweit <hkallweit1@...il.com>
---
drivers/net/phy/phy.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
index 890ae1d73..a898fa411 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -739,6 +739,8 @@ static void phy_error(struct phy_device *phydev)
phydev->state = PHY_HALTED;
mutex_unlock(&phydev->lock);
+ phydev_err(phydev, "stopping PHY state machine due to error\n");
+
phy_trigger_machine(phydev);
}
--
2.20.0
Powered by blists - more mailing lists