diff mbox series

[ethtool,4/4] netlink: add message descriptions for pause stats

Message ID 1e3546d7f774db109f77c465e3d1f838ab7d169d.1603142897.git.mkubecek@suse.cz (mailing list archive)
State Not Applicable
Delegated to: Michal Kubecek
Headers show
Series add missing message descriptions | expand

Commit Message

Michal Kubecek Oct. 19, 2020, 9:32 p.m. UTC
Add message descriptions for pretty printing of new attributes used for pause
statistics.

Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
---
 netlink/desc-ethtool.c | 7 +++++++
 1 file changed, 7 insertions(+)
diff mbox series

Patch

diff --git a/netlink/desc-ethtool.c b/netlink/desc-ethtool.c
index ee8fc4796987..96291b9bdd3b 100644
--- a/netlink/desc-ethtool.c
+++ b/netlink/desc-ethtool.c
@@ -180,12 +180,19 @@  static const struct pretty_nla_desc __coalesce_desc[] = {
 	NLATTR_DESC_U32(ETHTOOL_A_COALESCE_RATE_SAMPLE_INTERVAL),
 };
 
+static const struct pretty_nla_desc __pause_stats_desc[] = {
+	NLATTR_DESC_BINARY(ETHTOOL_A_PAUSE_STAT_PAD),
+	NLATTR_DESC_U64(ETHTOOL_A_PAUSE_STAT_TX_FRAMES),
+	NLATTR_DESC_U64(ETHTOOL_A_PAUSE_STAT_RX_FRAMES),
+};
+
 static const struct pretty_nla_desc __pause_desc[] = {
 	NLATTR_DESC_INVALID(ETHTOOL_A_PAUSE_UNSPEC),
 	NLATTR_DESC_NESTED(ETHTOOL_A_PAUSE_HEADER, header),
 	NLATTR_DESC_BOOL(ETHTOOL_A_PAUSE_AUTONEG),
 	NLATTR_DESC_BOOL(ETHTOOL_A_PAUSE_RX),
 	NLATTR_DESC_BOOL(ETHTOOL_A_PAUSE_TX),
+	NLATTR_DESC_NESTED(ETHTOOL_A_PAUSE_STATS, pause_stats),
 };
 
 static const struct pretty_nla_desc __eee_desc[] = {