psu-ng: Add a clearVinUVFault function

Create a clearVinUVFault() function specifically for clearing the VIN_UV
and unit is off fault bits.

Use this function when see a vinUVFault with good voltage read back from
READ_VIN. This should clear the latched fault if the fault is no longer
active. If the fault is still active, the next read will show the fault
again.

Also call clearVinUVFault() from the clearFaults() function.

Signed-off-by: Brandon Wyman <bjwyman@gmail.com>
Change-Id: Ic26029fe64e3cd3e232c615b223cafb774bf77f9
diff --git a/phosphor-power-supply/power_supply.hpp b/phosphor-power-supply/power_supply.hpp
index 3cc7fcb..6f1044c 100644
--- a/phosphor-power-supply/power_supply.hpp
+++ b/phosphor-power-supply/power_supply.hpp
@@ -126,6 +126,22 @@
     }
 
     /**
+     * @brief Function to specifically clear VIN_UV/OFF fault(s).
+     *
+     * The PMBus HWMON device driver has various alarm "files" to read out of
+     * sysfs. Reading those files will indicate if various alarms are active or
+     * not, and then specifically clear those faults that go with that alarm.
+     *
+     * The VIN_UV fault, indicated in STATUS_INPUT, goes with in1_lcrit_alarm.
+     * When a VIN_UV fault occurs, the "Unit Off For Insufficient Input Voltage"
+     * may also be active. Reading in1_lcrit_alarm should clear both fault bits,
+     * resulting in the corresponding fault bits in STATUS_WORD also clearing.
+     *
+     * See: https://www.kernel.org/doc/html/latest/hwmon/pmbus.html
+     */
+    void clearVinUVFault();
+
+    /**
      * Write PMBus CLEAR_FAULTS
      *
      * This function will be called in various situations in order to clear