diff options
author | Tim Lee <timlee660101@gmail.com> | 2020-06-18 04:28:26 +0300 |
---|---|---|
committer | Andrew Geissler <geissonator@yahoo.com> | 2020-07-29 02:51:39 +0300 |
commit | f7fc57b1abe73166f169503ee825fa1c96f888d1 (patch) | |
tree | 4baf5a26c6244c4b6d4d9a7cd3797e6007a4d4d4 /meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb | |
parent | 6215a1a34c53aa2a91f003e31222baaf0d3b56cb (diff) | |
download | openbmc-f7fc57b1abe73166f169503ee825fa1c96f888d1.tar.xz |
meta-quanta: olympus-nuvoton: power: update psu inventory over pmbus
According to PMBUS spec, there is an Inventory Information we can update to PSU inventory.
MFR_ID - Manufacturer
MFR_MODEL - Model
MFR_SERIAL - SerialNumber
IC_DEVICE_ID - PartNumber
redfish/v1/Chassis/chassis/Power
"PowerSupplies": [{
"@odata.id": "/redfish/v1/Chassis/chassis/Power#/PowerSupplies/0",
"Manufacturer": "FlexPower",
"MemberId": "powersupply0",
"Model": "MIS-S-1020",
"Name": "powersupply0",
"PartNumber": "FPS-213-D0000293-101",
"PowerInputWatts": 104.0,
"PowerOutputWatts": 61.5,
"SerialNumber": "MISPS1839A0A0RW",
"Status": {
"Health": "OK",
"State": "Enabled"
}}],
Tested: Verified for Olympus platform
(From meta-quanta rev: cbb46b95df93a6102ebf18c0bf6105f8f6482451)
Signed-off-by: Joseph Liu <kwliu@nuvoton.com>
Signed-off-by: Tim Lee <timlee660101@gmail.com>
Change-Id: I2714293957919193b36effdaa2c07cb8e6eabda4
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Diffstat (limited to 'meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb')
-rw-r--r-- | meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb b/meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb new file mode 100644 index 000000000..ed9c13687 --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-olympus-nuvoton/power/first-boot-set-psu.bb @@ -0,0 +1,22 @@ +SUMMARY = "Init PSU inventory" +DESCRIPTION = "Setup PSU inventory read from PSU" +PR = "r1" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" + +inherit allarch systemd + +RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils}" +RDEPENDS_${PN} += "bash" + +SYSTEMD_SERVICE_${PN} = "first-boot-set-psu@.service" +SYSTEMD_SERVICE_${PN} += "first-boot-set-psu@0-2-0x58.service" + +SRC_URI = "file://${BPN}.sh file://${BPN}@.service" + +S = "${WORKDIR}" +do_install() { + install -d ${D}${bindir} ${D}${systemd_system_unitdir} + install ${BPN}.sh ${D}${bindir}/ + install -m 644 ${BPN}@.service ${D}${systemd_system_unitdir}/ +} |