netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: davem@davemloft.net
Cc: alexanderduyck@fb.com, netdev@vger.kernel.org,
	edumazet@google.com, pabeni@redhat.com, andrew+netdev@lunn.ch,
	horms@kernel.org, Jakub Kicinski <kuba@kernel.org>,
	jdamato@fastly.com
Subject: [PATCH net-next 1/5] net: report csum_complete via qstats
Date: Tue, 11 Feb 2025 10:13:52 -0800	[thread overview]
Message-ID: <20250211181356.580800-2-kuba@kernel.org> (raw)
In-Reply-To: <20250211181356.580800-1-kuba@kernel.org>

Commit 13c7c941e729 ("netdev: add qstat for csum complete") reserved
the entry for csum complete in the qstats uAPI. Start reporting this
value now that we have a driver which needs it.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
CC: jdamato@fastly.com
---
 include/net/netdev_queues.h | 1 +
 net/core/netdev-genl.c      | 1 +
 2 files changed, 2 insertions(+)

diff --git a/include/net/netdev_queues.h b/include/net/netdev_queues.h
index 73d3401261a6..825141d675e5 100644
--- a/include/net/netdev_queues.h
+++ b/include/net/netdev_queues.h
@@ -23,6 +23,7 @@ struct netdev_queue_stats_rx {
 	u64 hw_drops;
 	u64 hw_drop_overruns;
 
+	u64 csum_complete;
 	u64 csum_unnecessary;
 	u64 csum_none;
 	u64 csum_bad;
diff --git a/net/core/netdev-genl.c b/net/core/netdev-genl.c
index 0dcd4faefd8d..c18bb53d13fd 100644
--- a/net/core/netdev-genl.c
+++ b/net/core/netdev-genl.c
@@ -581,6 +581,7 @@ netdev_nl_stats_write_rx(struct sk_buff *rsp, struct netdev_queue_stats_rx *rx)
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_ALLOC_FAIL, rx->alloc_fail) ||
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_HW_DROPS, rx->hw_drops) ||
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_HW_DROP_OVERRUNS, rx->hw_drop_overruns) ||
+	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_CSUM_COMPLETE, rx->csum_complete) ||
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_CSUM_UNNECESSARY, rx->csum_unnecessary) ||
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_CSUM_NONE, rx->csum_none) ||
 	    netdev_stat_put(rsp, NETDEV_A_QSTATS_RX_CSUM_BAD, rx->csum_bad) ||
-- 
2.48.1


  reply	other threads:[~2025-02-11 18:14 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-11 18:13 [PATCH net-next 0/5] eth: fbnic: report software queue stats Jakub Kicinski
2025-02-11 18:13 ` Jakub Kicinski [this message]
2025-02-11 19:34   ` [PATCH net-next 1/5] net: report csum_complete via qstats Joe Damato
2025-02-11 18:13 ` [PATCH net-next 2/5] eth: fbnic: wrap tx queue stats in a struct Jakub Kicinski
2025-02-11 19:41   ` Joe Damato
2025-02-11 18:13 ` [PATCH net-next 3/5] eth: fbnic: report software Rx queue stats Jakub Kicinski
2025-02-11 19:49   ` Joe Damato
2025-02-11 18:13 ` [PATCH net-next 4/5] eth: fbnic: report software Tx " Jakub Kicinski
2025-02-11 19:52   ` Joe Damato
2025-02-11 18:13 ` [PATCH net-next 5/5] eth: fbnic: re-sort the objects in the Makefile Jakub Kicinski
2025-02-11 19:54   ` Joe Damato
2025-02-11 22:32     ` Jakub Kicinski
2025-02-12 16:17       ` Alexander Lobakin
2025-02-13  0:50 ` [PATCH net-next 0/5] eth: fbnic: report software queue stats patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250211181356.580800-2-kuba@kernel.org \
    --to=kuba@kernel.org \
    --cc=alexanderduyck@fb.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=jdamato@fastly.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).