Sync keyword update to inherited FRUs
This commit syncs keyword update to all inherited FRUs.
When a keyword value is updated either from vpd-tool or from vpd-manager
WriteKeyword API, the keyword update should also be synced to all
inherited FRUs on PIM to prevent mismatch.
Test:
```
Tested on a rainier 2s2u simics setup.
1. Ensure BMC is in Ready state
2. Read VINI PN of /system/chassis/motherboard using vpd-tool
3. Update VINI PN of /system/chassis/motherboard using vpd-tool
4. Once vpd-tool returns success, read VINI PN of inherited FRUs
/system/chassis and /system/chassis/motherboard/tod_battery
5. VINI PN value should be same on the inherited FRUs.
```
Change-Id: Iff7340a111722f9e5336c0c846a79ffec8bbb8db
Signed-off-by: Souvik Roy <souvikroyofficial10@gmail.com>
diff --git a/vpd-manager/src/manager.cpp b/vpd-manager/src/manager.cpp
index ade45b7..fadd965 100644
--- a/vpd-manager/src/manager.cpp
+++ b/vpd-manager/src/manager.cpp
@@ -197,6 +197,14 @@
l_fruPath + "]");
}
}
+
+ // update keyword in inherited FRUs
+ if (l_rc != constants::FAILURE)
+ {
+ vpdSpecificUtility::updateKwdOnInheritedFrus(
+ l_fruPath, i_paramsToWriteData, l_sysCfgJsonObj);
+ }
+
return l_rc;
}
catch (const std::exception& l_exception)