linux-kernelorg-stable/tools/include/uapi/linux
Jakub Kicinski ab63a2387c netdev: add per-queue statistics
The ethtool-nl family does a good job exposing various protocol
related and IEEE/IETF statistics which used to get dumped under
ethtool -S, with creative names. Queue stats don't have a netlink
API, yet, and remain a lion's share of ethtool -S output for new
drivers. Not only is that bad because the names differ driver to
driver but it's also bug-prone. Intuitively drivers try to report
only the stats for active queues, but querying ethtool stats
involves multiple system calls, and the number of stats is
read separately from the stats themselves. Worse still when user
space asks for values of the stats, it doesn't inform the kernel
how big the buffer is. If number of stats increases in the meantime
kernel will overflow user buffer.

Add a netlink API for dumping queue stats. Queue information is
exposed via the netdev-genl family, so add the stats there.
Support per-queue and sum-for-device dumps. Latter will be useful
when subsequent patches add more interesting common stats than
just bytes and packets.

The API does not currently distinguish between HW and SW stats.
The expectation is that the source of the stats will either not
matter much (good packets) or be obvious (skb alloc errors).

Acked-by: Stanislav Fomichev <sdf@google.com>
Reviewed-by: Amritha Nambiar <amritha.nambiar@intel.com>
Reviewed-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
Link: https://lore.kernel.org/r/20240306195509.1502746-2-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2024-03-07 21:13:25 -08:00
..
tc_act
bpf.h bpf: Replace bpf_lpm_trie_key 0-length array with flexible array 2024-02-29 22:52:43 +01:00
bpf_common.h
bpf_perf_event.h
btf.h
const.h tools headers UAPI: Sync the linux/const.h with the kernel headers 2023-05-10 14:19:20 -03:00
erspan.h
ethtool.h
fadvise.h
fcntl.h tools headers UAPI: Sync linux/fcntl.h with the kernel sources 2024-01-26 10:51:48 -03:00
filter.h
fs.h fs/proc/task_mmu: report SOFT_DIRTY bits through the PAGEMAP_SCAN ioctl 2023-12-10 16:51:35 -08:00
fscrypt.h tools headers UAPI: Update tools's copy of fscrypt.h header 2023-11-22 10:57:46 -08:00
hw_breakpoint.h Move bp_type_idx to include/linux/hw_breakpoint.h 2023-03-10 21:05:16 +01:00
if_link.h bonding: Add independent control state machine 2024-02-06 13:17:54 +01:00
if_tun.h
if_xdp.h xsk: Add option to calculate TX checksum in SW 2023-11-29 14:59:40 -08:00
in.h tools headers UAPI: Sync the linux/in.h with the kernel sources 2023-05-26 16:03:27 -03:00
io_uring.h tools headers: Grab copy of io_uring.h 2023-10-19 16:42:03 -06:00
kcmp.h
kvm.h tools headers UAPI: Sync kvm headers with the kernel sources 2024-01-27 15:29:47 -03:00
mman.h tools headers UAPI: Sync files changed by new cachestat syscall with the kernel sources 2023-07-11 11:41:15 -03:00
mount.h tools include UAPI: Sync linux/mount.h copy with the kernel sources 2024-01-30 11:49:54 -03:00
netdev.h netdev: add per-queue statistics 2024-03-07 21:13:25 -08:00
netlink.h
openat2.h
perf_event.h tools headers UAPI: Sync include/uapi/linux/perf_event.h header with the kernel 2023-11-06 18:13:34 -03:00
pkt_cls.h net/sched: Remove uapi support for tcindex classifier 2024-01-02 14:25:51 +00:00
pkt_sched.h net/sched: Remove uapi support for CBQ qdisc 2024-01-02 14:25:51 +00:00
prctl.h mm: add a NO_INHERIT flag to the PR_SET_MDWE prctl 2023-10-06 14:44:11 -07:00
sched.h
seccomp.h tools headers UAPI: Copy seccomp.h to be able to build 'perf bench' in older systems 2023-09-13 08:48:48 -03:00
seg6.h
seg6_local.h
stat.h tools headers uapi: Sync linux/stat.h with the kernel sources to pick STATX_MNT_ID_UNIQUE 2024-01-26 10:51:48 -03:00
stddef.h
tcp.h
tls.h
types.h
usbdevice_fs.h
vhost.h tools headers UAPI: Update tools's copy of vhost.h header 2023-11-22 10:57:46 -08:00