aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIdo Schimmel <idosch@nvidia.com>2023-11-29 17:06:12 +0200
committerMichal Kubecek <mkubecek@suse.cz>2024-01-28 17:22:14 +0100
commit1a1dcfca4d670dbe01374ceb4e7c9c71ae75e15c (patch)
tree0f62bf6f8a194e936cf5e08e64a68b8253645732
parent7e3ccd489f522825117e1367f79465d267a04f58 (diff)
downloadethtool-1a1dcfca4d670dbe01374ceb4e7c9c71ae75e15c.tar.gz
ethtool: Fix SFF-8472 transceiver module identification
According to table 5-1 in SFF-8472 Rev. 12.4, the Identifier Values for "GBIC" (01h) and "Module soldered to motherboard (ex: SFF)" (02h) are supported by the specification in addition to the current one. Therefore, adjust ethtool to invoke the SFF-8079 parser for them, which will in turn invoke the SFF-8472 parser if the transceiver module supports digital diagnostic monitoring. Without this patch, the EEPROM contents of such transceiver modules will be hex dumped instead of being parsed and printed in a human readable format. Fixes: 25b64c66f58d ("ethtool: Add netlink handler for getmodule (-m)") Reported-by: Ivar Simensen <is@datarespons.no> Closes: https://lore.kernel.org/netdev/AM0PR03MB5938EE1722EF2C75112B86F5B9B9A@AM0PR03MB5938.eurprd03.prod.outlook.com/ Tested-by: Ivar Simensen <is@datarespons.no> Signed-off-by: Ido Schimmel <idosch@nvidia.com>
-rw-r--r--netlink/module-eeprom.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/netlink/module-eeprom.c b/netlink/module-eeprom.c
index 09ad580..fe02c5a 100644
--- a/netlink/module-eeprom.c
+++ b/netlink/module-eeprom.c
@@ -216,6 +216,8 @@ static int eeprom_parse(struct cmd_context *ctx)
switch (request.data[0]) {
#ifdef ETHTOOL_ENABLE_PRETTY_DUMP
+ case SFF8024_ID_GBIC:
+ case SFF8024_ID_SOLDERED_MODULE:
case SFF8024_ID_SFP:
return sff8079_show_all_nl(ctx);
case SFF8024_ID_QSFP: