Message ID | 20210118161731.2837700-8-olteanv@gmail.com |
---|---|
State | New |
Headers | show |
Series | [v3,net-next,01/15] net: dsa: tag_8021q: add helpers to deduce whether a VLAN ID is RX or TX VLAN | expand |
diff --git a/drivers/net/ethernet/mscc/ocelot_vsc7514.c b/drivers/net/ethernet/mscc/ocelot_vsc7514.c index d4cf6eeff3c9..76fa681b41f4 100644 --- a/drivers/net/ethernet/mscc/ocelot_vsc7514.c +++ b/drivers/net/ethernet/mscc/ocelot_vsc7514.c @@ -701,9 +701,10 @@ static irqreturn_t ocelot_xtr_irq_handler(int irq, void *arg) dev->stats.rx_packets++; } - if (err < 0) - while (ocelot_read(ocelot, QS_XTR_DATA_PRESENT) & BIT(grp)) - ocelot_read_rix(ocelot, QS_XTR_RD, grp); + if (err < 0) { + ocelot_write(ocelot, QS_XTR_FLUSH, BIT(grp)); + ocelot_write(ocelot, QS_XTR_FLUSH, 0); + } return IRQ_HANDLED; }