A few things to check:
Does the insertion and removal of the SFP generate events in dmesg?
# Insert
sfp dpmac2_sfp: module FS SFPP-PC01 rev R sn F1930247305-1 dc 200917
# Remove
sfp dpmac2_sfp: module removed
Is your kernel detecting all I2C busses?
You should have three I2C busses from the system, plus a mux/switch on i2c-2 (PCA9540) which
handles the two SFP cages.
# ls -la /sys/bus/i2c/devices/
total 0
drwxr-xr-x 2 root root 0 Mar 10 22:08 .
drwxr-xr-x 4 root root 0 Mar 10 22:08 ..
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0011 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0011
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0018 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0018
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-001a -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-001a
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0029 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0029
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-002f -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-002f
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-004c -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-004c
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0061 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0061
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0063 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0063
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0065 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0065
lrwxrwxrwx 1 root root 0 Mar 10 22:08 0-0076 -> ../../../devices/platform/soc/2000000.i2c/i2c-0/0-0076
lrwxrwxrwx 1 root root 0 Mar 10 22:08 1-0032 -> ../../../devices/platform/soc/2020000.i2c/i2c-1/1-0032
lrwxrwxrwx 1 root root 0 Mar 10 22:08 2-0070 -> ../../../devices/platform/soc/2030000.i2c/i2c-2/2-0070
lrwxrwxrwx 1 root root 0 Mar 10 22:08 i2c-0 -> ../../../devices/platform/soc/2000000.i2c/i2c-0
lrwxrwxrwx 1 root root 0 Mar 10 22:08 i2c-1 -> ../../../devices/platform/soc/2020000.i2c/i2c-1
lrwxrwxrwx 1 root root 0 Mar 10 22:08 i2c-2 -> ../../../devices/platform/soc/2030000.i2c/i2c-2
lrwxrwxrwx 1 root root 0 Mar 10 22:08 i2c-3 -> ../../../devices/platform/soc/2030000.i2c/i2c-2/i2c-3
lrwxrwxrwx 1 root root 0 Mar 10 22:08 i2c-4 -> ../../../devices/platform/soc/2030000.i2c/i2c-2/i2c-4
If you have i2cdetect
, running it on i2c-3 (eth9 / upper) or i2c-4 (eth8 / lower) should show the module EEPROM present on address 0x50:
i2cdetect 4
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-4.
I will probe address range 0x08-0x77.
Continue? [Y/n] y
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- --
...
50: 50 -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: UU -- -- -- -- -- -- --
Some “active” SFPs (like 1/10GBase-T) will additionally expose their internal phy on another I2C address.
If you the run i2cdump on the module EEPROM, it should read out successfully:
# For eth8 SFP:
$ i2cdump 4 0x50
No size specified (using byte-data access)
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-4, address 0x50, mode byte
Continue? [Y/n] y
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 03 04 21 00 00 00 00 00 04 00 00 00 67 00 00 00 ??!.....?...g...
10: 00 00 01 00 46 53 20 20 20 20 20 20 20 20 20 20 ..?.FS
20: 20 20 20 20 00 00 40 20 53 46 50 50 2d 50 43 30 ..@ SFPP-PC0
30: 31 20 20 20 20 20 20 20 52 20 20 20 01 00 00 3a 1 R ?..:
40: 00 00 00 00 46 31 39 33 30 32 34 37 33 30 35 2d ....F1930247305-
(truncated)
It looks like 6.2 changed the GPIO chip numbering/base as well. What is your output of ls -la /sys/class/gpio
?
ls -la /sys/class/gpio/
total 0
drwxr-xr-x 2 root root 0 Mar 10 22:45 .
drwxr-xr-x 67 root root 0 Mar 10 22:45 ..
--w------- 1 root root 4096 Mar 10 22:50 export
lrwxrwxrwx 1 root root 0 Mar 10 22:45 gpiochip512 -> ../../devices/platform/soc/2300000.gpio/gpio/gpiochip512
lrwxrwxrwx 1 root root 0 Mar 10 22:45 gpiochip544 -> ../../devices/platform/soc/2310000.gpio/gpio/gpiochip544
lrwxrwxrwx 1 root root 0 Mar 10 22:45 gpiochip576 -> ../../devices/platform/soc/2320000.gpio/gpio/gpiochip576
lrwxrwxrwx 1 root root 0 Mar 10 22:45 gpiochip608 -> ../../devices/platform/soc/2330000.gpio/gpio/gpiochip608
lrwxrwxrwx 1 root root 0 Mar 10 22:45 gpiochip640 -> ../../devices/platform/soc/2000000.i2c/i2c-0/0-0076/gpio/gpiochip640
So anything that referenced GPIOs 368-383 should be re-based to 640+