power-utils: Implement isReadyToUpdate
Check other PSUs' status word and status vout, return false when the
status has input/output fault.
Tested: Verify on Witherspoon that the update is not started and log
Unable to update PSU when other PSU has input/ouput fault
when the other PSU has input/output error;
And the update continues when the other PSU has no errors.
Signed-off-by: Lei YU <mine260309@gmail.com>
Change-Id: Ia2a4a23a43c18a417b8a85fbd5339f487984e689
diff --git a/types.hpp b/types.hpp
index 90b5c6a..d334a25 100644
--- a/types.hpp
+++ b/types.hpp
@@ -9,6 +9,8 @@
constexpr auto INVENTORY_MGR_IFACE = "xyz.openbmc_project.Inventory.Manager";
constexpr auto ASSET_IFACE = "xyz.openbmc_project.Inventory.Decorator.Asset";
constexpr auto VERSION_IFACE = "xyz.openbmc_project.Software.Version";
+constexpr auto PSU_INVENTORY_IFACE =
+ "xyz.openbmc_project.Inventory.Item.PowerSupply";
constexpr auto ENDPOINTS_PROP = "endpoints";
constexpr auto MESSAGE_PROP = "Message";