提交 665e350d 编写于 作者: S Satish Baddipadige 提交者: David S. Miller

bnxt_en: Increment checksum error counter only if NETIF_F_RXCSUM is set.

rx_l4_csum_error is now incremented only when offload is enabled
Signed-off-by: NSatish Baddipadige <sbaddipa@broadcom.com>
Signed-off-by: NMichael Chan <mchan@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 2731d70f
......@@ -1187,9 +1187,11 @@ static int bnxt_rx_pkt(struct bnxt *bp, struct bnxt_napi *bnapi, u32 *raw_cons,
skb->csum_level = RX_CMP_ENCAP(rxcmp1);
}
} else {
if (rxcmp1->rx_cmp_cfa_code_errors_v2 & RX_CMP_L4_CS_ERR_BITS)
if (rxcmp1->rx_cmp_cfa_code_errors_v2 & RX_CMP_L4_CS_ERR_BITS) {
if (dev->features & NETIF_F_RXCSUM)
cpr->rx_l4_csum_errors++;
}
}
skb_record_rx_queue(skb, bnapi->index);
skb_mark_napi_id(skb, &bnapi->napi);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册