]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
net: stmmac: xgmac: Add RBU handling in DMA interrupt
authorJose Abreu <Jose.Abreu@synopsys.com>
Wed, 4 Sep 2019 13:16:54 +0000 (15:16 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 5 Sep 2019 10:19:54 +0000 (12:19 +0200)
Add the handling of Receive Buffer Unavailable interrupt in the DMA
handler of XGMAC cores.

Signed-off-by: Jose Abreu <joabreu@synopsys.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/dwxgmac2_dma.c

index 64956465c03019edb0d8f5c2c61f3f61d0f50192..e77eb0ddf9b565639bb7aa4d733af8082c2e7cf3 100644 (file)
@@ -322,6 +322,10 @@ static int dwxgmac2_dma_interrupt(void __iomem *ioaddr,
 
        /* ABNORMAL interrupts */
        if (unlikely(intr_status & XGMAC_AIS)) {
+               if (unlikely(intr_status & XGMAC_RBU)) {
+                       x->rx_buf_unav_irq++;
+                       ret |= handle_rx;
+               }
                if (unlikely(intr_status & XGMAC_TPS)) {
                        x->tx_process_stopped_irq++;
                        ret |= tx_hard_error;