From: Jakub Kicinski <kuba@kernel•org>
To: Xuan Zhuo <xuanzhuo@linux•alibaba.com>
Cc: netdev@vger•kernel.org, "David S. Miller" <davem@davemloft•net>,
Eric Dumazet <edumazet@google•com>,
Paolo Abeni <pabeni@redhat•com>,
"Michael S. Tsirkin" <mst@redhat•com>,
Jason Wang <jasowang@redhat•com>,
Alexei Starovoitov <ast@kernel•org>,
Daniel Borkmann <daniel@iogearbox•net>,
Jesper Dangaard Brouer <hawk@kernel•org>,
John Fastabend <john.fastabend@gmail•com>,
Stanislav Fomichev <sdf@google•com>,
Amritha Nambiar <amritha.nambiar@intel•com>,
Larysa Zaremba <larysa.zaremba@intel•com>,
Sridhar Samudrala <sridhar.samudrala@intel•com>,
Maciej Fijalkowski <maciej.fijalkowski@intel•com>,
virtualization@lists•linux.dev, bpf@vger•kernel.org
Subject: Re: [PATCH net-next v4 3/8] virtio_net: support device stats
Date: Thu, 14 Mar 2024 15:54:25 -0700 [thread overview]
Message-ID: <20240314155425.74b8c601@kernel.org> (raw)
In-Reply-To: <20240314085459.115933-4-xuanzhuo@linux.alibaba.com>
On Thu, 14 Mar 2024 16:54:54 +0800 Xuan Zhuo wrote:
> make virtio-net support getting the stats from the device by ethtool -S
> <eth0>.
>
> Due to the numerous descriptors stats, an organization method is
> required. For this purpose, I have introduced the "virtnet_stats_map".
> Utilizing this array simplifies coding tasks such as generating field
> names, calculating buffer sizes for requests and responses, and parsing
> replies from the device. By iterating over the "virtnet_stats_map,"
> these operations become more streamlined and efficient.
Don't duplicate the stats which get reported via the netlink API in
ethtool. Similar story to the rtnl stats:
https://docs.kernel.org/next/networking/statistics.html#notes-for-driver-authors
next prev parent reply other threads:[~2024-03-14 22:54 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-14 8:54 [PATCH net-next v4 0/8] virtio-net: support device stats Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 1/8] virtio_net: introduce device stats feature and structures Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 2/8] virtio_net: virtnet_send_command supports command-specific-result Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 3/8] virtio_net: support device stats Xuan Zhuo
2024-03-14 22:54 ` Jakub Kicinski [this message]
2024-03-15 8:05 ` Xuan Zhuo
2024-03-19 17:15 ` Jakub Kicinski
2024-03-20 8:12 ` Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 4/8] virtio_net: stats map include driver stats Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 5/8] virtio_net: add the total stats field Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 6/8] virtio_net: rename stat tx_timeout to timeout Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 7/8] netdev: add queue stats Xuan Zhuo
2024-03-14 23:21 ` Jakub Kicinski
2024-03-15 8:11 ` Xuan Zhuo
2024-03-14 8:54 ` [PATCH net-next v4 8/8] virtio-net: support queue stat Xuan Zhuo
2024-03-14 22:56 ` Jakub Kicinski
2024-03-15 8:10 ` Xuan Zhuo
2024-03-14 10:47 ` [PATCH net-next v4 0/8] virtio-net: support device stats Paolo Abeni
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=20240314155425.74b8c601@kernel.org \
--to=kuba@kernel$(echo .)org \
--cc=amritha.nambiar@intel$(echo .)com \
--cc=ast@kernel$(echo .)org \
--cc=bpf@vger$(echo .)kernel.org \
--cc=daniel@iogearbox$(echo .)net \
--cc=davem@davemloft$(echo .)net \
--cc=edumazet@google$(echo .)com \
--cc=hawk@kernel$(echo .)org \
--cc=jasowang@redhat$(echo .)com \
--cc=john.fastabend@gmail$(echo .)com \
--cc=larysa.zaremba@intel$(echo .)com \
--cc=maciej.fijalkowski@intel$(echo .)com \
--cc=mst@redhat$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=pabeni@redhat$(echo .)com \
--cc=sdf@google$(echo .)com \
--cc=sridhar.samudrala@intel$(echo .)com \
--cc=virtualization@lists$(echo .)linux.dev \
--cc=xuanzhuo@linux$(echo .)alibaba.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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