psu-firmware-update: add optional override param

The previous design only updated the PSU if the image in the BMC
filesystem was newer than the version on the PSU. These changes
allowed for an optional override parameter to be used by the
vendor-specific tools to download the version from the BMC filesystem
to the PSU regardless of level of the firmware.

This is useful if the PSU needs to be back-leveled due to problems
later found in the new version of PSU firmware.

Change-Id: If8100b061a266a5aa0068880c8524cb359b41ced
Signed-off-by: Derek Howard <derekh@us.ibm.com>
diff --git a/designs/psu-firmware-update.md b/designs/psu-firmware-update.md
index fd62d6f..9c43313 100644
--- a/designs/psu-firmware-update.md
+++ b/designs/psu-firmware-update.md
@@ -41,7 +41,9 @@
    filesystem, BMC shall update the PSU firmware;
 3. When a PSU is replaced and the version is older than the one in BMC's
    filesystem, BMC shall update the PSU firmware.
-4. There are cases that a system could use different models of PSUs, and thus
+4. An optional 'override' parameter may be specified to do the update in the
+   above cases regardless of which PSU image is newer.
+5. There are cases that a system could use different models of PSUs, and thus
    different PSU firmware images need to be supported.
 
 For some PSUs, it is risky to do PSU code update while the host is running to
@@ -136,15 +138,15 @@
 ### Update on replaced PSU
 
 When a PSU is replaced, and the firmware version is older than the one in BMC
-filesystem, it shall be updated. This will be done by the same service described
-above.
+filesystem (or if the optional 'override' parameter is specified), it shall be
+updated. This will be done by the same service described above.
 
 1. On start, the service will subscribe to the PropertiesChanged signal to the
    PSU object path to monitor the PSU presence status. (Or maybe subscribe the
    InterfacesAdded/Removed signal?)
 2. When a PSU's presence status is changed from false to true (or the
-   InterfacesAdded event occurs), the service will check the new PSU's model,
-   firmware version to decide if the firmware needs to be updated.
+   PropertiesChanged event occurs), the service will check the new PSU's model
+   and firmware version to decide if the firmware needs to be updated.
 3. If yes, the service will find the matched vendor-specific tool to perform the
    code update.
 4. The following process will be the same as [Update by API].
@@ -198,9 +200,9 @@
 - Verify the PSU code update will fail if the vendor-specific tool fails on
   pre-condition check, of fails on updating PSU.
 - Verify the PSU code update is performed after a new BMC image is updated
-  containing a new version of PSU firmware.
-- Verify the PSU code update is performed after a PSU with old firmware is
-  plugged in.
+  containing a new (or different, if 'override' used) version of PSU firmware.
+- Verify the PSU code update is performed after a PSU with old (or different, if
+  'override' is used) firmware is plugged in.
 
 [1]:
   https://github.com/openbmc/phosphor-dbus-interfaces/tree/master/yaml/xyz/openbmc_project/Software