svn commit: r319506 - head/sys/dev/cxgbe
Navdeep Parhar
np at FreeBSD.org
Fri Jun 2 17:57:28 UTC 2017
Author: np
Date: Fri Jun 2 17:57:27 2017
New Revision: 319506
URL: https://svnweb.freebsd.org/changeset/base/319506
Log:
cxgbe(4): Update the statistics for compound tx work requests once per
work request, not once per frame.
MFC after: 1 week
Sponsored by: Chelsio Communications
Modified:
head/sys/dev/cxgbe/t4_sge.c
Modified: head/sys/dev/cxgbe/t4_sge.c
==============================================================================
--- head/sys/dev/cxgbe/t4_sge.c Fri Jun 2 17:49:21 2017 (r319505)
+++ head/sys/dev/cxgbe/t4_sge.c Fri Jun 2 17:57:27 2017 (r319506)
@@ -4581,12 +4581,8 @@ write_txpkts_wr(struct sge_txq *txq, struct fw_eth_tx_
if (checkwrap &&
(uintptr_t)cpl == (uintptr_t)&eq->desc[eq->sidx])
cpl = (void *)&eq->desc[0];
- txq->txpkts0_pkts += txp->npkt;
- txq->txpkts0_wrs++;
} else {
cpl = flitp;
- txq->txpkts1_pkts += txp->npkt;
- txq->txpkts1_wrs++;
}
/* Checksum offload */
@@ -4619,6 +4615,14 @@ write_txpkts_wr(struct sge_txq *txq, struct fw_eth_tx_
write_gl_to_txd(txq, m, (caddr_t *)(&flitp), checkwrap);
+ }
+
+ if (txp->wr_type == 0) {
+ txq->txpkts0_pkts += txp->npkt;
+ txq->txpkts0_wrs++;
+ } else {
+ txq->txpkts1_pkts += txp->npkt;
+ txq->txpkts1_wrs++;
}
txsd = &txq->sdesc[eq->pidx];
More information about the svn-src-head
mailing list