Back up and Restore update
The commit updates the flow of Back up and Restore of system VPD.
Updates:
- Removing call_out_inventory_path tag from the PEL create call
in case there is any issue while backup or restore.
This was done to avoid any calls from phosphor-logging to
VPD-Manager at this stage as Manager service is not up at this
point resulting in a D-Bus call failure.
- Removing dupicate code as and where possible in the flow.
The commit is an extension of following commit:
https://gerrit.openbmc.org/c/openbmc/openpower-vpd-parser/+/62250/
Tests:
PEL was created duringthe flow and confirmed that there was no
call to VPD-Manager from phosphor-logging.
Tested for all te scenarios w.r.t backup and restore of system
VPD.
Signed-off-by: Sunny Srivastava <sunnsr25@in.ibm.com>
Change-Id: I92779247438bf50d907fd7f60ed94dda6fadb2a0
diff --git a/ibm_vpd_utils.cpp b/ibm_vpd_utils.cpp
index cf3a798..d5d280c 100644
--- a/ibm_vpd_utils.cpp
+++ b/ibm_vpd_utils.cpp
@@ -672,6 +672,14 @@
{
kwVal = findKwd->second;
}
+ else
+ {
+ std::cout << "Keyword not found" << std::endl;
+ }
+ }
+ else
+ {
+ std::cerr << "Record not found" << std::endl;
}
return kwVal;