Add in support for detecting an output overcurrent fault
When analyzing the STATUS_WORD bits, check if the IOUT_OC_FAULT bit is
on. That bit indicates that an output overcurrent fault condition has
occurred. Call out the power supply reporting that.
Change-Id: I18c7cd981ffc1b73ab52c90d32ba34195013e65e
Signed-off-by: Brandon Wyman <bjwyman@gmail.com>
diff --git a/xyz/openbmc_project/Power/Fault.errors.yaml b/xyz/openbmc_project/Power/Fault.errors.yaml
index 4f270e4..f49234b 100644
--- a/xyz/openbmc_project/Power/Fault.errors.yaml
+++ b/xyz/openbmc_project/Power/Fault.errors.yaml
@@ -4,6 +4,8 @@
description: The power supply has indicated an input fault or warn condition.
- name: PowerSupplyShouldBeOn
description: The power supply indicated that it is not on when it should be.
+- name: PowerSupplyOutputOvercurrent
+ description: The power supply detected an output overcurrent fault condition.
- name: Shutdown
description: A power off was issued because a power fault was detected
diff --git a/xyz/openbmc_project/Power/Fault.metadata.yaml b/xyz/openbmc_project/Power/Fault.metadata.yaml
index 1615734..f4bc147 100644
--- a/xyz/openbmc_project/Power/Fault.metadata.yaml
+++ b/xyz/openbmc_project/Power/Fault.metadata.yaml
@@ -15,6 +15,13 @@
type: string
inherits:
- xyz.openbmc_project.Common.Callout.Inventory
+- name: PowerSupplyOutputOvercurrent
+ level: ERR
+ meta:
+ - str: "RAW_STATUS=%s"
+ type: string
+ inherits:
+ - xyz.openbmc_project.Common.Callout.Inventory
- name: Shutdown
level: ERR