commit | 0975eaf4fa852a49a78968d2f38c9b8c3477dbcf | [log] [tgz] |
---|---|---|
author | Matt Spinler <spinler@us.ibm.com> | Mon Feb 14 15:38:30 2022 -0600 |
committer | Shawn McCarney <shawnmm@us.ibm.com> | Thu Feb 17 22:00:13 2022 +0000 |
tree | e974b529cfec7508a1f4fc0e83047246cab5cb9e | |
parent | 5c6ac77e5e35f173a35bf432ecc6d457e63159c7 [diff] |
psu-ng: Add Availability support to power supplies Add support for determining if a power supply is considered 'available' or not, and set the Available D-Bus property on the xyz.openbmc_project.State.Decorator.Availability interface with the result. A power supply is considered unavailable if any of the following are true: - it isn't present - there is a input fault active - there is a Vin UV fault active - there is a PS KILL fault active - there is a Iout OC fault active The latter four faults are the faults where it can't provide good output power, hence the PS is unavailable. These faults also don't call out the power supply directly, so the Functional property won't get set to false, unlike other faults. The Available D-Bus property is then able to be used in Redfish responses for the heath and state properties in the power supply schema. Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I349eddb8c052cf238276c832af0dde9e49f6d3f0
This repository contains applications for configuring and monitoring devices that deliver power to the system.
To build all applications in this repository:
meson build ninja -C build
To clean the repository and remove all build output:
rm -rf build
You can specify meson options to customize the build process. For example, you can specify:
Several applications in this repository require a PSU JSON config to run. The JSON config file provides information for:
There is an example psu.json to describe the necessary configurations.
inventoryPMBusAccessType
defines the pmbus access type, which tells the service which sysfs type to use to read the attributes. The possible values are:/sys/bus/i2c/devices/3-0069/
/sys/bus/i2c/devices/3-0069/hwmon/hwmonX/
/sys/kernel/debug/pmbus/hwmonX/
/sys/kernel/debug/pmbus/hwmonX/cffps1/
fruConfigs
defines the mapping between the attribute file and the FRU inventory interface and property. The configuration example below indicates that the service will read part_number
attribute file from a directory specified by the above pmbus access type, and assign to PartNumber
property in xyz.openbmc_project.Inventory.Decorator.Asset
interface."fruConfigs": [ { "propertyName": "PartNumber", "fileName": "part_number", "interface": "xyz.openbmc_project.Inventory.Decorator.Asset" } ]
psuDevices
defines the kernel device dir for each PSU in inventory. The configuration example below indicates that powersupply0
's device is located in /sys/bus/i2c/devices/3-0069
."psuDevices": { "/xyz/openbmc_project/inventory/system/chassis/motherboard/powersupply0" : "/sys/bus/i2c/devices/3-0069", }