Factor PS derating into power cap limit validation
When the BMC sends a system power cap to the host, the host
validates it is in a certain range or it will reject it. So,
the BMC also checks the range before sending it at all.
This range comes out of the MRW (machine readable workbook)
XML, and is stored as output power. The user, however,
inputs the power cap value as input power, and so the range
the BMC code checks it against must also be in input power.
To support this, the script that pulls the power cap min
and max values out of the MRW for use in settings validation
will now convert those output power values into input power
by applying the power supply derating factor.
Resolves openbmc/openbmc#2944
Tested: Check that the power cap range that the settings manager
uses is now the input power versions.
Change-Id: Id5c5851d081ad706fda73054b49e67a93d57f76e
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
1 file changed