aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/sfc/tx.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2013-04-26 20:55:21 -0400
committerBen Hutchings <bhutchings@solarflare.com>2013-08-27 17:28:47 -0400
commit02e121650b5e46ef3f2b3ed1ebc4b70e47799056 (patch)
treefff130923bf82cde0bc0359384edf2d4cd359967 /drivers/net/ethernet/sfc/tx.c
parent43a3739d559f02cb00d92a51d8f2a7d294a1b5e5 (diff)
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 'drivers/net/ethernet/sfc/tx.c')
-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)
437 efx_dequeue_buffers(tx_queue, index, &pkts_compl, &bytes_compl); 437 efx_dequeue_buffers(tx_queue, index, &pkts_compl, &bytes_compl);
438 netdev_tx_completed_queue(tx_queue->core_txq, pkts_compl, bytes_compl); 438 netdev_tx_completed_queue(tx_queue->core_txq, pkts_compl, bytes_compl);
439 439
440 if (pkts_compl > 1)
441 ++tx_queue->merge_events;
442
440 /* See if we need to restart the netif queue. This memory 443 /* See if we need to restart the netif queue. This memory
441 * barrier ensures that we write read_count (inside 444 * barrier ensures that we write read_count (inside
442 * efx_dequeue_buffers()) before reading the queue status. 445 * efx_dequeue_buffers()) before reading the queue status.