1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-12 14:29:28 +00:00

This patch fixes a nit in the em, lem, and igb driver statistics. Increment

adapter->dropped_pkts instead of if_ierrors because if_ierrors is
overwritten by hw stats collection.

Submitted by:	Andrew Boyer <aboyer@averesystems.com>
Reviewed by:	Jack F Vogel <jfv@freebsd.org>
MFC after:	2 weeks
This commit is contained in:
Sean Bruno 2012-09-23 22:53:39 +00:00
parent c622f88dd2
commit 126a39ce60
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=240879
3 changed files with 3 additions and 3 deletions

View File

@ -4436,7 +4436,7 @@ em_rxeof(struct rx_ring *rxr, int count, int *done)
if ((cur->errors & E1000_RXD_ERR_FRAME_ERR_MASK) ||
(rxr->discard == TRUE)) {
ifp->if_ierrors++;
adapter->dropped_pkts++;
++rxr->rx_discarded;
if (!eop) /* Catch subsequent segs */
rxr->discard = TRUE;

View File

@ -4759,7 +4759,7 @@ igb_rxeof(struct igb_queue *que, int count, int *done)
/* Make sure all segments of a bad packet are discarded */
if (((staterr & E1000_RXDEXT_ERR_FRAME_ERR_MASK) != 0) ||
(rxr->discard)) {
ifp->if_ierrors++;
adapter->dropped_pkts++;
++rxr->rx_discarded;
if (!eop) /* Catch subsequent segs */
rxr->discard = TRUE;

View File

@ -3562,7 +3562,7 @@ lem_rxeof(struct adapter *adapter, int count, int *done)
adapter->lmp = NULL;
}
} else {
ifp->if_ierrors++;
adapter->dropped_pkts++;
discard:
/* Reuse loaded DMA map and just update mbuf chain */
mp = adapter->rx_buffer_area[i].m_head;