diff options
author | Anton Vorontsov <avorontsov@ru.mvista.com> | 2008-12-18 08:23:26 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-12-18 22:48:55 -0800 |
commit | 1762a29ae5ebdd974eb2ba0c36b56ab6f7a9c16d (patch) | |
tree | d78e6058cf6ba22d92ac593c64c0dcfaa9951577 /drivers/net/ucc_geth.h | |
parent | b3431c647662a3647f3500a12ec85d65e3622759 (diff) | |
download | blackbird-op-linux-1762a29ae5ebdd974eb2ba0c36b56ab6f7a9c16d.tar.gz blackbird-op-linux-1762a29ae5ebdd974eb2ba0c36b56ab6f7a9c16d.zip |
ucc_geth: Fix TX watchdog timeout handling
The timeout handling code is currently broken in several ways:
- It calls stop() (which frees all the memory and IRQ), and then
calls startup() (which won't re-request IRQ, neither it will
re-init the Fast UCC structure).
- It calls these routines from the softirq context, which is wrong,
since stop() calls free_irq() (which might sleep) and startup()
allocates things with GFP_KERNEL.
- It won't soft-reset the PHY. We need the PHY reset for at least
MPC8360E-MDS boards with Marvell 88E1111 PHY, the PHY won't recover
from timeouts w/o the reset.
So the patch fixes these problems by implementing the workqueue for the
timeout handling, and there we fully re-open the device via close() and
open() calls. The close/open paths do the right things, and I can see
that the driver actually survive the timeouts.
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ucc_geth.h')
-rw-r--r-- | drivers/net/ucc_geth.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ucc_geth.h b/drivers/net/ucc_geth.h index abc0e2242634..d74d2f7cb739 100644 --- a/drivers/net/ucc_geth.h +++ b/drivers/net/ucc_geth.h @@ -1186,6 +1186,7 @@ struct ucc_geth_private { struct ucc_fast_private *uccf; struct net_device *dev; struct napi_struct napi; + struct work_struct timeout_work; struct ucc_geth __iomem *ug_regs; struct ucc_geth_init_pram *p_init_enet_param_shadow; struct ucc_geth_exf_global_pram __iomem *p_exf_glbl_param; |