* [PATCH] net: lpc_eth: Fix crash on ip link up
@ 2014-09-01 11:46 stigge
2014-09-02 20:22 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: stigge @ 2014-09-01 11:46 UTC (permalink / raw)
To: davem, netdev, linux-kernel; +Cc: Roland Stigge
From: Roland Stigge <stigge@antcom.de>
When a link is already up, the following sequence makes the kernel
block completely:
ip link set dev eth0 down
ip link set dev eth0 up
This is because on suspended phy, the following lines
__lpc_eth_reset(pldat);
__lpc_eth_init(pldat);
make the LPC ethernet core block (see LPC32x0 manual). The PHY needs to be
(re-)activated low-level first.
Signed-off-by: Roland Stigge <stigge@antcom.de>
---
Applies to v3.17-rc3
drivers/net/ethernet/nxp/lpc_eth.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/nxp/lpc_eth.c b/drivers/net/ethernet/nxp/lpc_eth.c
index 8706c0d..a44a03c 100644
--- a/drivers/net/ethernet/nxp/lpc_eth.c
+++ b/drivers/net/ethernet/nxp/lpc_eth.c
@@ -1220,6 +1220,9 @@ static int lpc_eth_open(struct net_device *ndev)
__lpc_eth_clock_enable(pldat, true);
+ /* Suspended PHY makes LPC ethernet core block, so resume now */
+ phy_resume(pldat->phy_dev);
+
/* Reset and initialize */
__lpc_eth_reset(pldat);
__lpc_eth_init(pldat);
--
2.1.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: lpc_eth: Fix crash on ip link up
2014-09-01 11:46 [PATCH] net: lpc_eth: Fix crash on ip link up stigge
@ 2014-09-02 20:22 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2014-09-02 20:22 UTC (permalink / raw)
To: stigge; +Cc: netdev, linux-kernel
From: stigge@antcom.de
Date: Mon, 1 Sep 2014 13:46:46 +0200
> From: Roland Stigge <stigge@antcom.de>
>
> When a link is already up, the following sequence makes the kernel
> block completely:
>
> ip link set dev eth0 down
> ip link set dev eth0 up
>
> This is because on suspended phy, the following lines
>
> __lpc_eth_reset(pldat);
> __lpc_eth_init(pldat);
>
> make the LPC ethernet core block (see LPC32x0 manual). The PHY needs to be
> (re-)activated low-level first.
>
> Signed-off-by: Roland Stigge <stigge@antcom.de>
Applied, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-09-02 20:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-01 11:46 [PATCH] net: lpc_eth: Fix crash on ip link up stigge
2014-09-02 20:22 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).