netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [ethtool] ethtool: use "Not reported" when no FEC modes are provided
@ 2020-07-27 22:19 Jacob Keller
  0 siblings, 0 replies; only message in thread
From: Jacob Keller @ 2020-07-27 22:19 UTC (permalink / raw)
  To: Andrew Lunn, Michal Kubecek, netdev; +Cc: Jacob Keller

When displaying the FEC link modes advertised by the peer, we used the
string "No" to indicate when nothing was provided. This does not match
the IOCTL output which indicates "Not reported". It also doesn't match
the local advertised FEC modes, which also used the "Not reported"
string.

This is especially confusing for FEC, because the FEC bits include
a "None" bit which indicates that FEC is definitely not supported. Avoid
this confusion and match both the local advertised settings display and
the old IOCTL output by using "Not reported" when FEC settings aren't
reported.

Reported-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
---
 netlink/settings.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/netlink/settings.c b/netlink/settings.c
index 29557653336e..5616cb2f7b6f 100644
--- a/netlink/settings.c
+++ b/netlink/settings.c
@@ -473,7 +473,7 @@ static int dump_peer_modes(struct nl_context *nlctx, const struct nlattr *attr)
 
 	ret = dump_link_modes(nlctx, attr, true, LM_CLASS_FEC,
 			      "Link partner advertised FEC modes: ",
-			      " ", "\n", "No");
+			      " ", "\n", "Not reported");
 	return ret;
 }
 
-- 
2.26.2


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2020-07-27 22:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-27 22:19 [ethtool] ethtool: use "Not reported" when no FEC modes are provided Jacob Keller

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).