Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sensor_service: add DARWIN48V platform support #261

Closed

Conversation

adamcalabrigo
Copy link
Contributor

@adamcalabrigo adamcalabrigo commented Oct 8, 2024

Description

Adds initial sensor_service support for DARWIN48V platform. Note that this depends on the changes in #257. Monitored sensors are the same as DARWIN platform with the exception of PSU replacing PEM.

Test Plan

FBOSS OSS build passes with CentOS 9 and Linux kernel 6.4.

Validated on DARWIN48V hardware.

The sensor_service loads correctly:

# systemctl status sensor_service
● sensor_service.service - Start sensor_service
     Loaded: loaded (/etc/systemd/system/sensor_service.service; enabled; preset: disabled)
     Active: active (running) since Tue 2024-10-08 00:39:22 UTC; 1h 49min ago
   Main PID: 4894 (run_sensor_serv)
      Tasks: 38 (limit: 200901)
     Memory: 6.6M
        CPU: 48.135s
     CGroup: /system.slice/sensor_service.service
             ├─4894 /bin/bash /opt/fboss/bin/run_sensor_service.sh
             └─4896 /opt/fboss/bin/sensor_service -config_file /opt/fboss/share/platform_configs/sensor_service.json

All sensors are monitored without error:

I1008 00:39:22.653100  4896 PlatformNameLib.cpp:71] Platform name read from cache: DARWIN48V
I1008 00:39:22.653135  4896 ConfigLib.cpp:48] Using config file: /opt/fboss/share/platform_configs/sensor_service.json
I1008 00:39:22.653498  4896 SensorServiceImpl.cpp:42] FAN1_RPM: Path=/run/devmap/sensors/FAN_CPLD/fan1_input, Compute=, FRU=FAN1
I1008 00:39:22.653512  4896 SensorServiceImpl.cpp:42] FAN2_RPM: Path=/run/devmap/sensors/FAN_CPLD/fan2_input, Compute=, FRU=FAN2
I1008 00:39:22.653518  4896 SensorServiceImpl.cpp:42] FAN3_RPM: Path=/run/devmap/sensors/FAN_CPLD/fan3_input, Compute=, FRU=FAN3
I1008 00:39:22.653522  4896 SensorServiceImpl.cpp:42] FAN4_RPM: Path=/run/devmap/sensors/FAN_CPLD/fan4_input, Compute=, FRU=FAN4
I1008 00:39:22.653527  4896 SensorServiceImpl.cpp:42] FAN5_RPM: Path=/run/devmap/sensors/FAN_CPLD/fan5_input, Compute=, FRU=FAN5
I1008 00:39:22.653532  4896 SensorServiceImpl.cpp:42] PSU_FAN1_RPM: Path=/run/devmap/sensors/PSU_PMBUS/fan1_input, Compute=, FRU=PSU
I1008 00:39:22.653536  4896 SensorServiceImpl.cpp:42] PSU_FAN2_RPM: Path=/run/devmap/sensors/PSU_PMBUS/fan2_input, Compute=, FRU=PSU
I1008 00:39:22.653544  4896 SensorServiceImpl.cpp:42] PSU_IIN: Path=/run/devmap/sensors/PSU_PMBUS/curr1_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653552  4896 SensorServiceImpl.cpp:42] PSU_IOUT: Path=/run/devmap/sensors/PSU_PMBUS/curr2_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653567  4896 SensorServiceImpl.cpp:42] PSU_PIN: Path=/run/devmap/sensors/PSU_PMBUS/power1_input, Compute=@/1000000.0, FRU=PSU
I1008 00:39:22.653575  4896 SensorServiceImpl.cpp:42] PSU_POUT: Path=/run/devmap/sensors/PSU_PMBUS/power2_input, Compute=@/1000000.0, FRU=PSU
I1008 00:39:22.653583  4896 SensorServiceImpl.cpp:42] PSU_TEMP1: Path=/run/devmap/sensors/PSU_PMBUS/temp1_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653591  4896 SensorServiceImpl.cpp:42] PSU_TEMP2: Path=/run/devmap/sensors/PSU_PMBUS/temp2_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653599  4896 SensorServiceImpl.cpp:42] PSU_TEMP3: Path=/run/devmap/sensors/PSU_PMBUS/temp3_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653606  4896 SensorServiceImpl.cpp:42] PSU_VIN: Path=/run/devmap/sensors/PSU_PMBUS/in1_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653610  4896 SensorServiceImpl.cpp:42] PSU_VOUT: Path=/run/devmap/sensors/PSU_PMBUS/in3_input, Compute=@/1000.0, FRU=PSU
I1008 00:39:22.653617  4896 SensorServiceImpl.cpp:42] FS_FAN_RPM: Path=/run/devmap/sensors/FS_FAN_SLG4F4527/fan1_input, Compute=, FRU=RACKMON
I1008 00:39:22.653622  4896 SensorServiceImpl.cpp:42] BACK_PANEL_TEMP: Path=/run/devmap/sensors/CPU_BOARD_TEMP_MAX6658/temp2_input, Compute=@/1000.0, FRU=>
I1008 00:39:22.653626  4896 SensorServiceImpl.cpp:42] CPU_BOARD_TEMP: Path=/run/devmap/sensors/CPU_BOARD_TEMP_MAX6658/temp1_input, Compute=@/1000.0, FRU=S>
I1008 00:39:22.653631  4896 SensorServiceImpl.cpp:42] CPU_CORE0_TEMP: Path=/run/devmap/sensors/CPU_CORE_TEMP/temp2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653635  4896 SensorServiceImpl.cpp:42] CPU_CORE1_TEMP: Path=/run/devmap/sensors/CPU_CORE_TEMP/temp3_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653640  4896 SensorServiceImpl.cpp:42] CPU_CORE2_TEMP: Path=/run/devmap/sensors/CPU_CORE_TEMP/temp4_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653644  4896 SensorServiceImpl.cpp:42] CPU_CORE3_TEMP: Path=/run/devmap/sensors/CPU_CORE_TEMP/temp5_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653649  4896 SensorServiceImpl.cpp:42] CPU_PHYS_ID_0: Path=/run/devmap/sensors/CPU_CORE_TEMP/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653653  4896 SensorServiceImpl.cpp:42] FRONT_PANEL_TEMP: Path=/run/devmap/sensors/CPU_FP_TEMP_LM73/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653658  4896 SensorServiceImpl.cpp:42] MPS1_IIN: Path=/run/devmap/sensors/CPU_MPS1_PMBUS/curr1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653662  4896 SensorServiceImpl.cpp:42] MPS1_IOUT: Path=/run/devmap/sensors/CPU_MPS1_PMBUS/curr2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653667  4896 SensorServiceImpl.cpp:42] MPS1_TEMP: Path=/run/devmap/sensors/CPU_MPS1_PMBUS/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653671  4896 SensorServiceImpl.cpp:42] MPS1_VIN: Path=/run/devmap/sensors/CPU_MPS1_PMBUS/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653675  4896 SensorServiceImpl.cpp:42] MPS2_IIN: Path=/run/devmap/sensors/CPU_MPS2_PMBUS/curr1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653680  4896 SensorServiceImpl.cpp:42] MPS2_IOUT: Path=/run/devmap/sensors/CPU_MPS2_PMBUS/curr2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653684  4896 SensorServiceImpl.cpp:42] MPS2_TEMP: Path=/run/devmap/sensors/CPU_MPS2_PMBUS/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653688  4896 SensorServiceImpl.cpp:42] MPS2_VIN: Path=/run/devmap/sensors/CPU_MPS2_PMBUS/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653693  4896 SensorServiceImpl.cpp:42] POS_0V6_VTT: Path=/run/devmap/sensors/CPU_POS_UCD90160/in2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653697  4896 SensorServiceImpl.cpp:42] POS_12V: Path=/run/devmap/sensors/CPU_POS_UCD90160/in13_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653702  4896 SensorServiceImpl.cpp:42] POS_1V05_COM: Path=/run/devmap/sensors/CPU_POS_UCD90160/in6_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653706  4896 SensorServiceImpl.cpp:42] POS_1V2_ALW: Path=/run/devmap/sensors/CPU_POS_UCD90160/in11_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653710  4896 SensorServiceImpl.cpp:42] POS_1V2_LAN1: Path=/run/devmap/sensors/CPU_POS_UCD90160/in14_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653715  4896 SensorServiceImpl.cpp:42] POS_1V2_LAN2: Path=/run/devmap/sensors/CPU_POS_UCD90160/in15_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653719  4896 SensorServiceImpl.cpp:42] POS_1V2_VDDQ: Path=/run/devmap/sensors/CPU_POS_UCD90160/in3_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653723  4896 SensorServiceImpl.cpp:42] POS_1V3_KRHV: Path=/run/devmap/sensors/CPU_POS_UCD90160/in7_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653728  4896 SensorServiceImpl.cpp:42] POS_1V5_PCH: Path=/run/devmap/sensors/CPU_POS_UCD90160/in5_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653732  4896 SensorServiceImpl.cpp:42] POS_1V7_SCFUSE: Path=/run/devmap/sensors/CPU_POS_UCD90160/in8_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653737  4896 SensorServiceImpl.cpp:42] POS_1V7_VCCIN_VRRDY: Path=/run/devmap/sensors/CPU_POS_UCD90160/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653741  4896 SensorServiceImpl.cpp:42] POS_2V5_VPP: Path=/run/devmap/sensors/CPU_POS_UCD90160/in4_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653746  4896 SensorServiceImpl.cpp:42] POS_3V3: Path=/run/devmap/sensors/CPU_POS_UCD90160/in9_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653750  4896 SensorServiceImpl.cpp:42] POS_3V3_ALW: Path=/run/devmap/sensors/CPU_POS_UCD90160/in12_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653755  4896 SensorServiceImpl.cpp:42] POS_5V0: Path=/run/devmap/sensors/CPU_POS_UCD90160/in10_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653759  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_IIN: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/curr1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653763  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_IOUT_A: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/curr2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653769  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_IOUT_B: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/curr3_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653774  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_POUT_A: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/power2_input, Compute=@/1000000.0, FRU>
I1008 00:39:22.653778  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_POUT_B: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/power3_input, Compute=@/1000000.0, FRU>
I1008 00:39:22.653783  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_TEMP: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653787  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_VIN: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653791  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_VOUT_A: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/in2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653796  4896 SensorServiceImpl.cpp:42] QSFPDD_VRD_VOUT_B: Path=/run/devmap/sensors/SC_QSFPDD_IR35223/in3_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653800  4896 SensorServiceImpl.cpp:42] SC_BOARD_LEFT_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp3_input, Compute=@/1000.0, FR>
I1008 00:39:22.653804  4896 SensorServiceImpl.cpp:42] SC_BOARD_MIDDLE_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp2_input, Compute=@/1000.0, >
I1008 00:39:22.653809  4896 SensorServiceImpl.cpp:42] SC_BOARD_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653813  4896 SensorServiceImpl.cpp:42] SC_FRONT_PANEL_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp4_input, Compute=@/1000.0, F>
I1008 00:39:22.653818  4896 SensorServiceImpl.cpp:42] SC_POS_0V8_AVDD: Path=/run/devmap/sensors/SC_POS_UCD90320/in15_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653822  4896 SensorServiceImpl.cpp:42] SC_POS_0V9_VDD: Path=/run/devmap/sensors/SC_POS_UCD90320/in16_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653826  4896 SensorServiceImpl.cpp:42] SC_POS_12V_STDBY: Path=/run/devmap/sensors/SC_POS_UCD90320/in3_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653830  4896 SensorServiceImpl.cpp:42] SC_POS_12V_TH3_A: Path=/run/devmap/sensors/SC_POS_UCD90320/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653835  4896 SensorServiceImpl.cpp:42] SC_POS_12V_TH3_B: Path=/run/devmap/sensors/SC_POS_UCD90320/in2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653840  4896 SensorServiceImpl.cpp:42] SC_POS_1V2: Path=/run/devmap/sensors/SC_POS_UCD90320/in14_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653844  4896 SensorServiceImpl.cpp:42] SC_POS_1V5_A: Path=/run/devmap/sensors/SC_POS_UCD90320/in12_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653849  4896 SensorServiceImpl.cpp:42] SC_POS_1V5_B: Path=/run/devmap/sensors/SC_POS_UCD90320/in13_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653853  4896 SensorServiceImpl.cpp:42] SC_POS_1V8: Path=/run/devmap/sensors/SC_POS_UCD90320/in11_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653857  4896 SensorServiceImpl.cpp:42] SC_POS_2V5_LT: Path=/run/devmap/sensors/SC_POS_UCD90320/in9_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653862  4896 SensorServiceImpl.cpp:42] SC_POS_2V5_RT: Path=/run/devmap/sensors/SC_POS_UCD90320/in10_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653866  4896 SensorServiceImpl.cpp:42] SC_POS_3V3: Path=/run/devmap/sensors/SC_POS_UCD90320/in5_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653870  4896 SensorServiceImpl.cpp:42] SC_POS_3V3_QSFPDD_A: Path=/run/devmap/sensors/SC_POS_UCD90320/in6_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653875  4896 SensorServiceImpl.cpp:42] SC_POS_3V3_QSFPDD_B: Path=/run/devmap/sensors/SC_POS_UCD90320/in7_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653879  4896 SensorServiceImpl.cpp:42] SC_POS_3V3_STDBY: Path=/run/devmap/sensors/SC_POS_UCD90320/in8_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653884  4896 SensorServiceImpl.cpp:42] SC_POS_5V0: Path=/run/devmap/sensors/SC_POS_UCD90320/in4_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653888  4896 SensorServiceImpl.cpp:42] SC_TH3_DIODE1_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp7_input, Compute=@/1000.0, FR>
I1008 00:39:22.653892  4896 SensorServiceImpl.cpp:42] SC_TH3_DIODE2_TEMP: Path=/run/devmap/sensors/SC_BOARD_TEMP_MAX6581/temp8_input, Compute=@/1000.0, FR>
I1008 00:39:22.653896  4896 SensorServiceImpl.cpp:42] TH3_VRD1_IIN: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/curr1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653901  4896 SensorServiceImpl.cpp:42] TH3_VRD1_IOUT: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/curr2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653905  4896 SensorServiceImpl.cpp:42] TH3_VRD1_POUT: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/power2_input, Compute=@/1000000.0, FRU=S>
I1008 00:39:22.653910  4896 SensorServiceImpl.cpp:42] TH3_VRD1_TEMP: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653915  4896 SensorServiceImpl.cpp:42] TH3_VRD1_VIN: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653919  4896 SensorServiceImpl.cpp:42] TH3_VRD1_VOUT: Path=/run/devmap/sensors/SC_TH3_CORE_IR35223/in2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653923  4896 SensorServiceImpl.cpp:42] TH3_VRD2_IIN: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/curr1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653928  4896 SensorServiceImpl.cpp:42] TH3_VRD2_IOUT: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/curr2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653932  4896 SensorServiceImpl.cpp:42] TH3_VRD2_POUT: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/power2_input, Compute=@/1000000.0, FRU=S>
I1008 00:39:22.653937  4896 SensorServiceImpl.cpp:42] TH3_VRD2_TEMP: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/temp1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653942  4896 SensorServiceImpl.cpp:42] TH3_VRD2_VIN: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/in1_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.653946  4896 SensorServiceImpl.cpp:42] TH3_VRD2_VOUT: Path=/run/devmap/sensors/SC_TH3_ANLG_IR35223/in2_input, Compute=@/1000.0, FRU=SMB
I1008 00:39:22.654316  4896 SensorServiceImpl.cpp:51] ========================================================
I1008 00:39:22.654332  4896 SensorServiceImpl.cpp:113] Fetching using legacy sensor structs...
I1008 00:39:22.975872  4896 SensorServiceImpl.cpp:124] In Total, Processed 91 Sensors. 0 Failures.

@facebook-github-bot
Copy link
Contributor

@joancaneus has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@facebook-github-bot
Copy link
Contributor

@adamcalabrigo has updated the pull request. You must reimport the pull request before landing.

@facebook-github-bot
Copy link
Contributor

@adamcalabrigo has updated the pull request. You must reimport the pull request before landing.

@facebook-github-bot
Copy link
Contributor

@adamcalabrigo has updated the pull request. You must reimport the pull request before landing.

@facebook-github-bot
Copy link
Contributor

@adamcalabrigo has updated the pull request. You must reimport the pull request before landing.

@facebook-github-bot
Copy link
Contributor

@joancaneus has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@facebook-github-bot
Copy link
Contributor

@joancaneus merged this pull request in f469422.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants