Bjørn Mork
2a912fb63a
realtek: enable HWMON for SFP sensors
This adds SFP sensors as a hwmon device, allowing readout of
temperatures, DOM and other sensor readings available from the
SFP. Example from a ZyXEL GS1900-10HP with a DOM capable
1000Base-SX SFP:
root@gs1900-10hp:~# grep . /sys/class/hwmon/hwmon0/*
/sys/class/hwmon/hwmon0/curr1_crit:90
/sys/class/hwmon/hwmon0/curr1_crit_alarm:0
/sys/class/hwmon/hwmon0/curr1_input:4
/sys/class/hwmon/hwmon0/curr1_label:bias
/sys/class/hwmon/hwmon0/curr1_lcrit:0
/sys/class/hwmon/hwmon0/curr1_lcrit_alarm:0
/sys/class/hwmon/hwmon0/curr1_max:85
/sys/class/hwmon/hwmon0/curr1_max_alarm:0
/sys/class/hwmon/hwmon0/curr1_min:0
/sys/class/hwmon/hwmon0/curr1_min_alarm:0
/sys/class/hwmon/hwmon0/in0_crit:3795
/sys/class/hwmon/hwmon0/in0_crit_alarm:0
/sys/class/hwmon/hwmon0/in0_input:3317
/sys/class/hwmon/hwmon0/in0_label:VCC
/sys/class/hwmon/hwmon0/in0_lcrit:2805
/sys/class/hwmon/hwmon0/in0_lcrit_alarm:0
/sys/class/hwmon/hwmon0/in0_max:3465
/sys/class/hwmon/hwmon0/in0_max_alarm:0
/sys/class/hwmon/hwmon0/in0_min:3135
/sys/class/hwmon/hwmon0/in0_min_alarm:0
/sys/class/hwmon/hwmon0/name:sfp_p10
/sys/class/hwmon/hwmon0/power1_crit:708
/sys/class/hwmon/hwmon0/power1_crit_alarm:0
/sys/class/hwmon/hwmon0/power1_input:259
/sys/class/hwmon/hwmon0/power1_label:TX_power
/sys/class/hwmon/hwmon0/power1_lcrit:89
/sys/class/hwmon/hwmon0/power1_lcrit_alarm:0
/sys/class/hwmon/hwmon0/power1_max:501
/sys/class/hwmon/hwmon0/power1_max_alarm:0
/sys/class/hwmon/hwmon0/power1_min:126
/sys/class/hwmon/hwmon0/power1_min_alarm:0
/sys/class/hwmon/hwmon0/power2_crit:1259
/sys/class/hwmon/hwmon0/power2_crit_alarm:0
/sys/class/hwmon/hwmon0/power2_input:404
/sys/class/hwmon/hwmon0/power2_label:RX_power
/sys/class/hwmon/hwmon0/power2_lcrit:6
/sys/class/hwmon/hwmon0/power2_lcrit_alarm:0
/sys/class/hwmon/hwmon0/power2_max:794
/sys/class/hwmon/hwmon0/power2_max_alarm:0
/sys/class/hwmon/hwmon0/power2_min:10
/sys/class/hwmon/hwmon0/power2_min_alarm:0
/sys/class/hwmon/hwmon0/temp1_crit:100000
/sys/class/hwmon/hwmon0/temp1_crit_alarm:0
/sys/class/hwmon/hwmon0/temp1_input:22547
/sys/class/hwmon/hwmon0/temp1_label:temperature
/sys/class/hwmon/hwmon0/temp1_lcrit:-50000
/sys/class/hwmon/hwmon0/temp1_lcrit_alarm:0
/sys/class/hwmon/hwmon0/temp1_max:85000
/sys/class/hwmon/hwmon0/temp1_max_alarm:0
/sys/class/hwmon/hwmon0/temp1_min:-40000
/sys/class/hwmon/hwmon0/temp1_min_alarm:0
/sys/class/hwmon/hwmon0/uevent:OF_NAME=sfp-p10
/sys/class/hwmon/hwmon0/uevent:OF_FULLNAME=/sfp-p10
/sys/class/hwmon/hwmon0/uevent:OF_COMPATIBLE_0=sff,sfp
/sys/class/hwmon/hwmon0/uevent:OF_COMPATIBLE_N=1
Tested-by: Birger Koblitz <mail@birger-koblitz.de>
Signed-off-by: Bjørn Mork <bjorn@mork.no>
2021-03-17 10:01:21 +01:00
..
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 12:38:38 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 12:38:38 +01:00
2021-03-13 17:06:35 +01:00
2021-03-12 21:09:11 +01:00
2021-03-14 19:11:05 +01:00
2021-03-08 12:45:10 +01:00
2021-03-17 08:10:54 +01:00
2021-03-16 20:06:00 +01:00
2021-03-06 11:30:06 +01:00
2021-03-16 19:27:55 +08:00
2021-03-06 11:30:06 +01:00
2021-03-06 19:05:53 +00:00
2021-03-06 19:05:53 +00:00
2021-01-25 14:37:41 +01:00
2021-03-12 18:49:46 +01:00
2021-03-12 18:49:46 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-03-15 16:40:31 +00:00
2021-03-06 11:30:06 +01:00
2021-03-13 20:15:29 +00:00
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-03-13 17:06:35 +01:00
2021-02-10 15:47:23 +01:00
2021-03-06 11:30:06 +01:00
2021-03-12 18:49:46 +01:00
2021-03-13 17:06:42 +01:00
2021-03-17 10:01:21 +01:00
2021-03-06 11:30:06 +01:00
2021-03-06 11:30:06 +01:00
2021-02-10 15:47:18 +01:00
2021-02-10 15:47:18 +01:00
2021-03-15 19:12:03 -07:00
2021-03-06 11:30:06 +01:00
2021-02-10 15:47:18 +01:00