From: Florian Fainelli Date: Thu, 5 Jun 2014 17:22:16 +0000 (-0700) Subject: net: systemport: correctly check for RX_STATUS_OVFLOW flag X-Git-Tag: firefly_0821_release~176^2~3765^2~60^2~2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=ad51c6106119adf8565adb179989a06ab4b865bb;p=firefly-linux-kernel-4.4.55.git net: systemport: correctly check for RX_STATUS_OVFLOW flag We were missing an and comparison with status to check whether RX_STATUS_OVFLOW is asserted or not in the per-packet status word, fix that. Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/broadcom/bcmsysport.c b/drivers/net/ethernet/broadcom/bcmsysport.c index 4dfc93fe9744..fc84aba0cde0 100644 --- a/drivers/net/ethernet/broadcom/bcmsysport.c +++ b/drivers/net/ethernet/broadcom/bcmsysport.c @@ -514,7 +514,7 @@ static unsigned int bcm_sysport_desc_rx(struct bcm_sysport_priv *priv, if (unlikely(status & (RX_STATUS_ERR | RX_STATUS_OVFLOW))) { netif_err(priv, rx_err, ndev, "error packet\n"); - if (RX_STATUS_OVFLOW) + if (status & RX_STATUS_OVFLOW) ndev->stats.rx_over_errors++; ndev->stats.rx_dropped++; ndev->stats.rx_errors++;