diff options
author | Nicolas Ferre <nicolas.ferre@atmel.com> | 2012-10-31 10:04:57 +0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-11-01 19:45:58 +0400 |
commit | e86cd53afc5907f7c221b709916e2dd354e14691 (patch) | |
tree | 9c07152729ebed99f79b910102e39113c0323ea5 /drivers/net/ethernet/cadence/macb.h | |
parent | d1d1b53d9d28c8e44a72fadae491702b36e2e1fb (diff) | |
download | linux-e86cd53afc5907f7c221b709916e2dd354e14691.tar.xz |
net/macb: better manage tx errors
Handle all TX errors, not only underruns. TX error management is
deferred to a dedicated workqueue.
Reinitialize the TX ring after treating all remaining frames, and
restart the controller when everything has been cleaned up properly.
Napi is not stopped during this task as the driver only handles
napi for RX for now.
With this sequence, we do not need a special check during the xmit
method as the packets will be caught by TX disable during workqueue
execution.
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Tested-by: Joachim Eastwood <manabian@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/cadence/macb.h')
-rw-r--r-- | drivers/net/ethernet/cadence/macb.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/cadence/macb.h b/drivers/net/ethernet/cadence/macb.h index 232dca6b5839..4235ab871ab4 100644 --- a/drivers/net/ethernet/cadence/macb.h +++ b/drivers/net/ethernet/cadence/macb.h @@ -538,6 +538,7 @@ struct macb { struct clk *hclk; struct net_device *dev; struct napi_struct napi; + struct work_struct tx_error_task; struct net_device_stats stats; union { struct macb_stats macb; |