aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/sfc/tx.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2013-04-27 01:55:21 +0100
committerBen Hutchings <bhutchings@solarflare.com>2013-08-27 22:28:47 +0100
commit02e121650b5e46ef3f2b3ed1ebc4b70e47799056 (patch)
treefff130923bf82cde0bc0359384edf2d4cd359967 /drivers/net/ethernet/sfc/tx.c
parentsfc: Generalise packet hash lookup to support EF10 RX prefix (diff)
downloadlinux-dev-02e121650b5e46ef3f2b3ed1ebc4b70e47799056.tar.xz
linux-dev-02e121650b5e46ef3f2b3ed1ebc4b70e47799056.zip
sfc: Add TX merged completion counter
Add a counter for TX merged completion events. This is implemented in the common TX path, because the NIC event handlers only know how many descriptors were completed, not how many packets. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Diffstat (limited to '')
-rw-r--r--drivers/net/ethernet/sfc/tx.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c
index 4903c4f7f292..85ee647b28ad 100644
--- a/drivers/net/ethernet/sfc/tx.c
+++ b/drivers/net/ethernet/sfc/tx.c
@@ -437,6 +437,9 @@ void efx_xmit_done(struct efx_tx_queue *tx_queue, unsigned int index)
efx_dequeue_buffers(tx_queue, index, &pkts_compl, &bytes_compl);
netdev_tx_completed_queue(tx_queue->core_txq, pkts_compl, bytes_compl);
+ if (pkts_compl > 1)
+ ++tx_queue->merge_events;
+
/* See if we need to restart the netif queue. This memory
* barrier ensures that we write read_count (inside
* efx_dequeue_buffers()) before reading the queue status.