diff options
author | Nathan Sullivan <nathan.sullivan@ni.com> | 2015-05-05 16:00:25 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-05-09 16:04:43 -0400 |
commit | bfbb92c446700da645e4834fb01439097846ce1e (patch) | |
tree | 3d8905fe44be94dc7187af8c724320f42ecb3335 /drivers/net/ethernet | |
parent | d3196a2468895c219a47f3c370713a4ca59c9f54 (diff) |
net: macb: Handle the RXUBR interrupt on all devices
The same hardware issue the at91 must work around applies to at least the
Zynq ethernet, and possibly more devices. The driver also needs to handle
the RXUBR interrupt since it turns it on with MACB_RX_INT_FLAGS anyway.
Signed-off-by: Nathan Sullivan <nathan.sullivan@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/cadence/macb.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c index 4104d49f005d..61aa570aad9a 100644 --- a/drivers/net/ethernet/cadence/macb.c +++ b/drivers/net/ethernet/cadence/macb.c | |||
@@ -981,7 +981,7 @@ static irqreturn_t macb_interrupt(int irq, void *dev_id) | |||
981 | struct macb_queue *queue = dev_id; | 981 | struct macb_queue *queue = dev_id; |
982 | struct macb *bp = queue->bp; | 982 | struct macb *bp = queue->bp; |
983 | struct net_device *dev = bp->dev; | 983 | struct net_device *dev = bp->dev; |
984 | u32 status; | 984 | u32 status, ctrl; |
985 | 985 | ||
986 | status = queue_readl(queue, ISR); | 986 | status = queue_readl(queue, ISR); |
987 | 987 | ||
@@ -1037,6 +1037,15 @@ static irqreturn_t macb_interrupt(int irq, void *dev_id) | |||
1037 | * add that if/when we get our hands on a full-blown MII PHY. | 1037 | * add that if/when we get our hands on a full-blown MII PHY. |
1038 | */ | 1038 | */ |
1039 | 1039 | ||
1040 | if (status & MACB_BIT(RXUBR)) { | ||
1041 | ctrl = macb_readl(bp, NCR); | ||
1042 | macb_writel(bp, NCR, ctrl & ~MACB_BIT(RE)); | ||
1043 | macb_writel(bp, NCR, ctrl | MACB_BIT(RE)); | ||
1044 | |||
1045 | if (bp->caps & MACB_CAPS_ISR_CLEAR_ON_WRITE) | ||
1046 | macb_writel(bp, ISR, MACB_BIT(RXUBR)); | ||
1047 | } | ||
1048 | |||
1040 | if (status & MACB_BIT(ISR_ROVR)) { | 1049 | if (status & MACB_BIT(ISR_ROVR)) { |
1041 | /* We missed at least one packet */ | 1050 | /* We missed at least one packet */ |
1042 | if (macb_is_gem(bp)) | 1051 | if (macb_is_gem(bp)) |