ethtool: Add support for OSFP transceiver modules
Subsystems (2)
PATCH 1/1 ethtool: Add support for OSFP transceiver modules
OSFP transceiver modules use the same management interface specification (CMIS) as QSFP-DD and DSFP modules.
Allow ethtool to dump, parse and print their EEPROM contents by adding their SFF-8024 Identifier Value (0x19).
This is required for future NVIDIA Spectrum-4 based systems that will be equipped with OSFP transceivers.
While at it, add the DSFP identifier to the IOCTL path, as it was missing.
--- netlink/module-eeprom.c | 1 + qsfp.c | 4 +++- sff-common.c | 3 +++ sff-common.h | 1 + 4 files changed, 8 insertions(+), 1 deletion(-)
netlink/module-eeprom.c +1 -0
@@ -223,6 +223,7 @@ static int eeprom_parse(struct cmd_context *ctx)case SFF8024_ID_QSFP_PLUS :return sff8636_show_all_nl (ctx);case SFF8024_ID_QSFP_DD : +case SFF8024_ID_OSFP :case SFF8024_ID_DSFP :return cmis_show_all_nl (ctx);#endif
qsfp.c +3 -1
@@ -947,7 +947,9 @@ void sff8636_show_all_ioctl(const __u8 *id, __u32 eeprom_len) {struct sff8636_memory_map map = {}; -if (id[SFF8636_ID_OFFSET ] ==SFF8024_ID_QSFP_DD ) { +if (id[SFF8636_ID_OFFSET ] ==SFF8024_ID_QSFP_DD || + id[SFF8636_ID_OFFSET ] ==SFF8024_ID_OSFP || + id[SFF8636_ID_OFFSET ] ==SFF8024_ID_DSFP ) {cmis_show_all_ioctl (id);return ; }
sff-common.c +3 -0
@@ -139,6 +139,9 @@ void sff8024_show_identifier(const __u8 *id, int id_offset)case SFF8024_ID_QSFP_DD :printf (" (QSFP-DD Double Density 8X Pluggable Transceiver (INF-8628))\n" );break ; +case SFF8024_ID_OSFP : +printf (" (OSFP 8X Pluggable Transceiver)\n" ); +break ;case SFF8024_ID_DSFP :printf (" (DSFP Dual Small Form Factor Pluggable Transceiver)\n" );break ;
sff-common.h +1 -0
@@ -62,6 +62,7 @@#define SFF8024_ID_CDFP_S3 0x16#define SFF8024_ID_MICRO_QSFP 0x17#define SFF8024_ID_QSFP_DD 0x18 +#define SFF8024_ID_OSFP 0x19#define SFF8024_ID_DSFP 0x1B#define SFF8024_ID_LAST SFF8024_ID_DSFP#define SFF8024_ID_UNALLOCATED_LAST 0x7F
Signature · 1 line
2.31.1
Hello Michal,
Can you please take the patch?
I haven't got any comment about it.
Thanks,
Danielle
Quoted 85 lines
-----Original Message-----
From: Danielle Ratson <[email protected]>
Sent: Monday, February 7, 2022 11:13 AM
To: [email protected]
Cc: [email protected]; Vadim Pasternak <[email protected]>; mlxsw <[email protected]>; Danielle Ratson <[email protected]>
Subject: [PATCH ethtool-next] ethtool: Add support for OSFP transceiver modulesOSFP transceiver modules use the same management interface specification (CMIS) as QSFP-DD and DSFP modules.
Allow ethtool to dump, parse and print their EEPROM contents by adding their SFF-8024 Identifier Value (
0x19).This is required for future NVIDIA Spectrum-4 based systems that will be equipped with OSFP transceivers.
While at it, add the DSFP identifier to the IOCTL path, as it was missing.
Signed-off-by Danielle Ratson <[email protected]>Reviewed-by Ido Schimmel <[email protected]>--- netlink/module-eeprom.c | 1 + qsfp.c | 4 +++- sff-common.c | 3 +++ sff-common.h | 1 + 4 files changed, 8 insertions(+), 1 deletion(-)netlink/module-eeprom.c index renamed from netlink/module-eeprom.c +0
-0f359aee..49833a2 100644
netlink/module-eeprom.c +1
-0@@ -223,6 +223,7 @@ static int eeprom_parse(struct cmd_context *ctx)case SFF8024_ID_QSFP_PLUS :return sff8636_show_all_nl (ctx);case SFF8024_ID_QSFP_DD : +case SFF8024_ID_OSFP :case SFF8024_ID_DSFP :return cmis_show_all_nl (ctx);#endif qsfp.c +3
-1@@ -947,7 +947,9 @@ void sff8636_show_all_ioctl(const __u8 *id, __u32 eeprom_len) {struct sff8636_memory_map map = {}; -if (id[SFF8636_ID_OFFSET ] ==SFF8024_ID_QSFP_DD ) { +if (id[SFF8636_ID_OFFSET ] ==SFF8024_ID_QSFP_DD || + id[SFF8636_ID_OFFSET ] ==SFF8024_ID_OSFP || + id[SFF8636_ID_OFFSET ] ==SFF8024_ID_DSFP ) {cmis_show_all_ioctl (id);return ; }sff-common.c +3
-0@@ -139,6 +139,9 @@ void sff8024_show_identifier(const __u8 *id, int id_offset)case SFF8024_ID_QSFP_DD : printf(" (QSFP-DD Double Density 8X Pluggable Transceiver (INF-8628))\n"); break; +case SFF8024_ID_OSFP : +printf (" (OSFP 8X Pluggable Transceiver)\n" ); +break ;case SFF8024_ID_DSFP :printf(" (DSFP Dual Small Form Factor Pluggable
Transceiver)\n");sff-common.c +0
-0break ;sff-common.h +1
-1@@ -62,6 +62,7 @@#define SFF8024_ID_CDFP_S3 0x16#define SFF8024_ID_MICRO_QSFP 0x17#define SFF8024_ID_QSFP_DD 0x18 +#define SFF8024_ID_OSFP 0x19#define SFF8024_ID_DSFP 0x1B#define SFF8024_ID_LAST SFF8024_ID_DSFP#define SFF8024_ID_UNALLOCATED_LAST 0x7F --2.31.1