Message ID | 20150128185833.GA10259@mwanda |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
From: Ding Tianhong <dingtianhong@huawei.com> Date: Thu, 29 Jan 2015 10:50:35 +0800 > On 2015/1/29 2:58, Dan Carpenter wrote: >> The if block was supposed to have curly braces. In the current code we >> complain about dropped rx packets when we shouldn't. >> >> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> >> > Acked-by: Ding Tianhong <dingtianhong@huawei.com> Applied, thanks everyone. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/ethernet/hisilicon/hip04_eth.c b/drivers/net/ethernet/hisilicon/hip04_eth.c index 525214e..c02b81b 100644 --- a/drivers/net/ethernet/hisilicon/hip04_eth.c +++ b/drivers/net/ethernet/hisilicon/hip04_eth.c @@ -567,10 +567,11 @@ static irqreturn_t hip04_mac_interrupt(int irq, void *dev_id) writel_relaxed(DEF_INT_MASK, priv->base + PPE_RINT); if (unlikely(ists & DEF_INT_ERR)) { - if (ists & (RCV_NOBUF | RCV_DROP)) + if (ists & (RCV_NOBUF | RCV_DROP)) { stats->rx_errors++; stats->rx_dropped++; netdev_err(ndev, "rx drop\n"); + } if (ists & TX_DROP) { stats->tx_dropped++; netdev_err(ndev, "tx drop\n");
The if block was supposed to have curly braces. In the current code we complain about dropped rx packets when we shouldn't. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html