summaryrefslogtreecommitdiff
path: root/meta-ibm
diff options
context:
space:
mode:
authorNaresh Solanki <naresh.solanki@9elements.com>2023-10-31 15:37:42 +0300
committerPatrick Rudolph <patrick.rudolph@9elements.com>2024-02-01 10:50:26 +0300
commit0ca9d72f8c77a845b21e4bc9b7e752770c5bf5b7 (patch)
treed1f9b89aed1a6598845f077f598786728eb98c5b /meta-ibm
parent4cc0b9091289f4cab319200abc61af6ef2190fb5 (diff)
downloadopenbmc-0ca9d72f8c77a845b21e4bc9b7e752770c5bf5b7.tar.xz
meta-ibm: sbp1: phosphor-virtual-sensor: Add sensor
The regulator PVCCD_HV_CPU* only has sensors to measure output power and input voltage. Calculate input power and input current for PVCCD_HV_CPU* based on output power and input voltage considering 90% efficiency. TEST: webui shows newly added PVCCD_HV_CPU* sensors. Change-Id: I3ae49beaca4453595116b640177fde822d195ab6 Signed-off-by: Naresh Solanki <naresh.solanki@9elements.com>
Diffstat (limited to 'meta-ibm')
-rw-r--r--meta-ibm/recipes-phosphor/sensors/phosphor-virtual-sensor/sbp1/virtual_sensor_config.json268
1 files changed, 268 insertions, 0 deletions
diff --git a/meta-ibm/recipes-phosphor/sensors/phosphor-virtual-sensor/sbp1/virtual_sensor_config.json b/meta-ibm/recipes-phosphor/sensors/phosphor-virtual-sensor/sbp1/virtual_sensor_config.json
index 82f65a1682..4386501424 100644
--- a/meta-ibm/recipes-phosphor/sensors/phosphor-virtual-sensor/sbp1/virtual_sensor_config.json
+++ b/meta-ibm/recipes-phosphor/sensors/phosphor-virtual-sensor/sbp1/virtual_sensor_config.json
@@ -169,5 +169,273 @@
]
},
"Expression": "ifNan(T0, 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU0_Input_Power",
+ "SensorType": "power"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU0_Output_Power",
+ "SensorType": "power"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / 0.9, 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU0_Input_Current",
+ "SensorType": "current"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU0_Output_Power",
+ "SensorType": "power"
+ }
+ },
+ {
+ "ParamName": "V0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU0_Input_Voltage",
+ "SensorType": "voltage"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / (V0 * 0.9), 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU1_Input_Power",
+ "SensorType": "power"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU1_Output_Power",
+ "SensorType": "power"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / 0.9, 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU1_Input_Current",
+ "SensorType": "current"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU1_Output_Power",
+ "SensorType": "power"
+ }
+ },
+ {
+ "ParamName": "V0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU1_Input_Voltage",
+ "SensorType": "voltage"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / (V0 * 0.9), 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU2_Input_Power",
+ "SensorType": "power"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU2_Output_Power",
+ "SensorType": "power"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / 0.9, 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU2_Input_Current",
+ "SensorType": "current"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU2_Output_Power",
+ "SensorType": "power"
+ }
+ },
+ {
+ "ParamName": "V0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU2_Input_Voltage",
+ "SensorType": "voltage"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / (V0 * 0.9), 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU3_Input_Power",
+ "SensorType": "power"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU3_Output_Power",
+ "SensorType": "power"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / 0.9, 0)"
+ },
+ {
+ "Desc": {
+ "Name": "PVCCD_HV_CPU3_Input_Current",
+ "SensorType": "current"
+ },
+ "Associations": [
+ [
+ "chassis",
+ "all_sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ],
+ [
+ "inventory",
+ "sensors",
+ "/xyz/openbmc_project/inventory/system/board/IBM_SBP1_Baseboard"
+ ]
+ ],
+ "Params": {
+ "DbusParam": [
+ {
+ "ParamName": "P0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU3_Output_Power",
+ "SensorType": "power"
+ }
+ },
+ {
+ "ParamName": "V0",
+ "Desc": {
+ "Name": "PVCCD_HV_CPU3_Input_Voltage",
+ "SensorType": "voltage"
+ }
+ }
+ ]
+ },
+ "Expression": "ifNan(P0 / (V0 * 0.9), 0)"
}
]