commit | 37bbf98c8ba77196ba72864846ca3b4a4ff5be4b | [log] [tgz] |
---|---|---|
author | Chris Cain <cjcain@us.ibm.com> | Mon Sep 20 10:53:09 2021 -0500 |
committer | Chris Cain <cjcain@us.ibm.com> | Tue Nov 02 13:27:36 2021 +0000 |
tree | 4d81fbdcea0f8fe343f9b2934351027a87c4503e | |
parent | 0a052baa566b3697419789dbf78934d43efc4ac4 [diff] |
Systems: Add IdlePowerSave support Idle power saver is a system wide mode that will reduce the power usage when the system reaches an idle state. The system will also exit idle power save once the performance increases to a specified utilization. The idle state is defined as when the processor utilization drops to EnterUtilizationPercent for EnterDwellTimeSeconds. Once the utilization increases to ExitUtilizationPercent for ExitDwellTimeSeconds, the system will return to normal (non-idle) state. Ran Validator on hardware and all /redfish/v1/Systems/system tests passed. Tested: I manually tested retrieving and setting the PowerMode property on a Rainier system (with good and bad values) $ curl -s -k -X GET https://$bmc/redfish/v1/Systems/system | grep -A6 IdlePowerSaver "IdlePowerSaver": { "Enabled": false, "EnterDwellTimeSeconds": 240, "EnterUtilizationPercent": 8, "ExitDwellTimeSeconds": 10, "ExitUtilizationPercent": 12 }, $ curl -k -X PATCH -d '{"IdlePowerSaver":{"Enabled":true}}' https://$bmc/redfish/v1/Systems/system $ curl -k -X PATCH -d '{"IdlePowerSaver":{"Enabled":false,"EnterUtilizationPercent":8,"EnterDwellTimeSeconds":240,"ExitUtilizationPercent":12,"ExitDwellTimeSeconds":10}}' https://$bmc/redfish/v1/Systems/system Signed-off-by: Chris Cain <cjcain@us.ibm.com> Change-Id: Icdc948f133959dce4297ab9774c2e9c8acb620e3
This component attempts to be a "do everything" embedded webserver for openbmc.
At this time, the webserver implements a few interfaces:
BMCWeb is configured by setting -D
flags that correspond to options in bmcweb/meson_options.txt
and then compiling. For example, meson <builddir> -Dkvm=disabled ...
followed by ninja
in build directory. The option names become C++ preprocessor symbols that control which code is compiled into the program.
meson builddir ninja -C builddir
meson builddir -Dbuildtype=minsize -Db_lto=true -Dtests=disabled ninja -C buildir
If any of the dependencies are not found on the host system during configuration, meson automatically gets them via its wrap dependencies mentioned in bmcweb/subprojects
.
meson builddir -Dwrap_mode=nofallback ninja -C builddir
meson builddir -Dbuildtype=debug ninja -C builddir
meson builddir -Db_coverage=true -Dtests=enabled ninja coverage -C builddir test
When BMCWeb starts running, it reads persistent configuration data (such as UUID and session data) from a local file. If this is not usable, it generates a new configuration.
When BMCWeb SSL support is enabled and a usable certificate is not found, it will generate a self-sign a certificate before launching the server. The keys are generated by the secp384r1
algorithm. The certificate
C=US, O=OpenBMC, CN=testhost
,SHA-256
algorithm.