Clear powerOnFault when inputFault cleared

The de-glitch counting for powerOnFault (ShouldBeOnFault) will stop when
a fault is found. The flag indicating a fault is found will be set if an
input fault is found. This also de-asserts Power_Good# and sets
UNIT_IS_OFF. The power supply cannot be on and have Power_Good# asserted
if it has an input fault. Clear the powerOnFault when inputFault is
cleared in order to reset the de-glitch to match up with the power on
delay.

Change-Id: I31f9db41077d89ebec01908eb916974102635c87
Signed-off-by: Brandon Wyman <bjwyman@gmail.com>
diff --git a/power-supply/power_supply.cpp b/power-supply/power_supply.cpp
index 0c42ca0..15fc432 100644
--- a/power-supply/power_supply.cpp
+++ b/power-supply/power_supply.cpp
@@ -309,6 +309,12 @@
         {
             inputFault = 0;
             faultFound = false;
+            // When an input fault occurs, the power supply cannot be on.
+            // However, the check for the case where the power supply should be
+            // on will stop when there is a fault found.
+            // Clear the powerOnFault when the inputFault is cleared to reset
+            // the powerOnFault de-glitching.
+            powerOnFault = 0;
 
             log<level::INFO>("INPUT_FAULT_WARN cleared",
                              entry("POWERSUPPLY=%s", inventoryPath.c_str()));