psu-ng: Refactor PGOOD and UNIT_IS_OFF fault
Split the code for detecting PGOOD and/or UNIT_IS_OFF fault into its own
private member function.
The analyze() function is getting a bit long and hard to read.
Change-Id: I48771a5d4e8991ce37b54bd6ad4c3e938924418e
Signed-off-by: Brandon Wyman <bjwyman@gmail.com>
diff --git a/phosphor-power-supply/power_supply.hpp b/phosphor-power-supply/power_supply.hpp
index 83ebc74..3cb5a6d 100644
--- a/phosphor-power-supply/power_supply.hpp
+++ b/phosphor-power-supply/power_supply.hpp
@@ -491,6 +491,11 @@
size_t readFail = 0;
/**
+ * @brief Examine STATUS_WORD for pgood or unit off faults.
+ */
+ void analyzePgoodFault();
+
+ /**
* @brief Determine possible manufacturer-specific faults from bits in
* STATUS_MFR.
*