]> git.baikalelectronics.ru Git - kernel.git/commit
ethtool: add a new command for reading standard stats
authorJakub Kicinski <kuba@kernel.org>
Fri, 16 Apr 2021 19:27:39 +0000 (12:27 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 16 Apr 2021 23:59:20 +0000 (16:59 -0700)
commitcc07919eb125f03fe9c9f11ae9c4706743eacdfe
treeb135481e6127588c4580f149a75d995964005db5
parentd14710608729509320d890b02b849b6c22405c7e
ethtool: add a new command for reading standard stats

Add an interface for reading standard stats, including
stats which don't have a corresponding control interface.

Start with IEEE 802.3 PHY stats. There seems to be only
one stat to expose there.

Define API to not require user space changes when new
stats or groups are added. Groups are based on bitset,
stats have a string set associated.

v1: wrap stats in a nest

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/ethtool.h
include/uapi/linux/ethtool.h
include/uapi/linux/ethtool_netlink.h
net/ethtool/Makefile
net/ethtool/netlink.c
net/ethtool/netlink.h
net/ethtool/stats.c [new file with mode: 0644]
net/ethtool/strset.c