summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVikram Bodireddy <vikram.bodireddy@linux.intel.com>2019-12-05 08:28:37 +0300
committerBodireddy, Vikram <vikram.bodireddy@intel.com>2019-12-06 05:15:56 +0300
commit77a2b54064f846c45679bd36f9047e4ee1a64a13 (patch)
tree63f930d6ccd174392e733936a640e16526521211
parent403daa54a9eb438935856c2503a6124b9a4099f3 (diff)
downloadprovingground-77a2b54064f846c45679bd36f9047e4ee1a64a13.tar.xz
Expose recovery img state as StandbySpare
In order to differentiate the recovery & active image, StandbySpare or Active value will be advertised accordingly by the inventory objects. Tested: 1. Verified that BMC / BIOS active or recovery image advertise the changes as Active / StandbySpare for the Activation state 2. With changes in bmcweb, the same will be marked as enabled / StandbySpare in the redfish schema query for the State property Change-Id: I511013c0f9e343a6b40607095057f889cd33e2af Signed-off-by: Vikram Bodireddy <vikram.bodireddy@linux.intel.com>
-rw-r--r--intel-pfr-manager/service/src/pfr_mgr.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/intel-pfr-manager/service/src/pfr_mgr.cpp b/intel-pfr-manager/service/src/pfr_mgr.cpp
index d5f1f59..318abe2 100644
--- a/intel-pfr-manager/service/src/pfr_mgr.cpp
+++ b/intel-pfr-manager/service/src/pfr_mgr.cpp
@@ -60,7 +60,10 @@ PfrVersion::PfrVersion(sdbusplus::asio::object_server &srv_,
* active, so we should set "activation" to Active and
* "RequestedActivation" to None. */
std::string activation =
- "xyz.openbmc_project.Software.Activation.Activations.Active";
+ (imgType == ImageType::bmcRecovery ||
+ imgType == ImageType::biosRecovery)
+ ? "xyz.openbmc_project.Software.Activation.Activations.StandbySpare"
+ : "xyz.openbmc_project.Software.Activation.Activations.Active";
std::string reqActNone =
"xyz.openbmc_project.Software.Activation.RequestedActivations.None";
auto activationIface = server.add_interface(