IPZ VPD Parser support
This commit enables the app ibm-read-vpd to read the
IPZ format vpd. To build this app, the application
build must be configured with the "--enable-ibm-parser"
option.
The application populates the Inventory with the parsed
VPD data. The parser relies on a JSON config file
that maps the input VPD file path to the Inventory D-Bus
object that hosts the VPD data as properties.
The JSON file also supplies any additional interfaces
and properties that the D-Bus object should implement.
Argument required to run this application-
ibm-read-vpd --file vpd_file
Tested:
Also tested this on Rainier simulation model and verified that VPD
for FRUs is properly published as properties of D-Bus objects in the
Inventory.
Change-Id: Ic9305f25625adced7f64123589dd083e2679afbb
Signed-off-by: Alpana Kumari <alpankum@in.ibm.com>
diff --git a/impl.hpp b/impl.hpp
index 94a958e..525ae7a 100644
--- a/impl.hpp
+++ b/impl.hpp
@@ -36,14 +36,14 @@
} // namespace internal
/** @class Impl
- * @brief Implements parser for OpenPOWER VPD
+ * @brief Implements parser for VPD
*
- * An Impl object must be constructed by passing in OpenPOWER VPD in
+ * An Impl object must be constructed by passing in VPD in
* binary format. To parse the VPD, call the run() method. The run()
* method returns an openpower::vpd::Store object, which contains
* parsed VPD, and provides access methods for the VPD.
*
- * Following is the algorithm used to parse OpenPOWER VPD:
+ * Following is the algorithm used to parse IPZ/OpenPower VPD:
* 1) Validate that the first record is VHDR, the header record.
* 2) From the VHDR record, get the offset of the VTOC record,
* which is the table of contents record.
@@ -66,13 +66,13 @@
/** @brief Construct an Impl
*
- * @param[in] vpdBuffer - Binary OpenPOWER VPD
+ * @param[in] vpdBuffer - Binary VPD
*/
explicit Impl(Binary&& vpdBuffer) : vpd(std::move(vpdBuffer)), out{}
{
}
- /** @brief Run the parser on binary OpenPOWER VPD
+ /** @brief Run the parser on binary VPD
*
* @returns openpower::vpd::Store object
*/
@@ -99,13 +99,13 @@
/** @brief Read VPD information contained within a record
*
* @param[in] recordOffset - offset to a record location
- * within the binary OpenPOWER VPD
+ * within the binary VPD
*/
void processRecord(std::size_t recordOffset);
/** @brief Read keyword data
*
- * @param[in] keyword - OpenPOWER VPD keyword
+ * @param[in] keyword - VPD keyword
* @param[in] dataLength - Length of data to be read
* @param[in] iterator - iterator pointing to a Keyword's data in
* the VPD
@@ -129,7 +129,7 @@
/** @brief Checks if the VHDR record is present in the VPD */
void checkHeader() const;
- /** @brief OpenPOWER VPD in binary format */
+ /** @brief VPD in binary format */
Binary vpd;
/** @brief parser output */