KNET: expose SFP info in tracked netifs - #4
Open
KanjiMonster wants to merge 1 commit into
Open
Conversation
Add support for exposing SFP module info in KNET tracked interfaces. The EEPROM's content is accessed via a nvmem device created by the optoe driver, while SFP signals are provided by userspace for now. The EEPROM layout follows ONL's optoe's driver's layout, i.e.: - for SFP modules, 0-255 is EEPROM at address 0x50 / 0xa0, 256-511 is 0x51 / 0xa2 - for QSFP modules, 0-127 is lower page 0, 128-255 is upper page 0, 256-383 is upper page 1 etc. Expose the type of SFP module via the port field to user space. In the future we can use this to dynamically configure the hardware based on the inserted module. Code for parsing the SFP EEPROM is taken from the kernel. Signed-off-by: Jonas Gorski <jonas.gorski@bisdn.de>
KanjiMonster
force-pushed
the
jogo_sfp_eeprom
branch
from
July 16, 2026 09:10
cf0ec9b to
624e0c0
Compare
KanjiMonster
marked this pull request as ready for review
July 16, 2026 12:03
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add support for exposing SFP module info in KNET tracked interfaces. The EEPROM's content is accessed via a nvmem device created by the optoe driver, while SFP signals are provided by userspace for now.
The EEPROM layout follows ONL's optoe's driver's layout, i.e.:
Expose the type of SFP module via the port field to user space. In the future we can use this to dynamically configure the hardware based on the inserted module.
Code for parsing the SFP EEPROM is taken from the kernel.
Depends on bisdn/meta-open-network-linux#237 for accessing the EEPROM.