commit | bd011b2f2ed79e0bdabad5dd548c68e518721f85 | [log] [tgz] |
---|---|---|
author | Santosh Puranik <santosh.puranik@in.ibm.com> | Thu Jan 23 04:05:25 2020 -0600 |
committer | SunnySrivastava1984 <sunnsr25@in.ibm.com> | Wed Jun 03 02:43:42 2020 -0500 |
tree | ce9bf3ea4f8d92bdc293e4111988db3fef929898 | |
parent | 8554f105a7c007f82989f0c86ecdf0f227d49194 [diff] |
Support multiple inventory objects per EEPROM This commit enables the IBM VPD parser to add multiple inventory objects based on the contents of a single EEPROM. An example would be inventory items that share data with the parent FRU that actually contains the VPD, such as an ethernet port on the BMC card. The commit also adds support for encoding keyword data in formats other than just converting them to string before publishing it on D-Bus. While this commit only adds MAC address as a possible encoding, more can be added in the future by specifying the encoding in the inventory JSON. Tested: Verified the following: * D-Bus objects added to the inventory for the BMC FRU and its associated connectors. * The ethernet objects are populated with the MACAddress property. Sample output from D-Bus: root@rainier:~# busctl get-property xyz.openbmc_project.Inventory.Manager /xyz/openbmc_project/inventory/system/chassis/motherboard/ebmc_card_bmc/ethernet0 xyz.openbmc_project.Inventory.Item.NetworkInterface MACAddress --no-pager s "00:11:25:c1:00:00" root@rainier:~# busctl get-property xyz.openbmc_project.Inventory.Manager /xyz/openbmc_project/inventory/system/chassis/motherboard/ebmc_card_bmc/ethernet1 xyz.openbmc_project.Inventory.Item.NetworkInterface MACAddress --no-pager s "00:11:25:c1:00:01" Signed-off-by: Santosh Puranik <santosh.puranik@in.ibm.com> Change-Id: Iee839b405c60e7e825f709e4ad0bb0f63d11a1b3
#Overview This repository hosts code for OpenPower and IBM IPZ format VPD parsers. Both OpenPower VPD and IPZ VPD formats are structured binaries that consist of records and keywords. A record is a collection of multiple keywords. More information about the format can be found here.
The repository consists of two distinct applications, which are:
This is a build-time YAML driven application that parses the OpenPower VPD format and uses the YAML configuration (see extra-properties-example.yaml and writefru.yaml) to determine:
The application instance must be passed in the file path to the VPD (this can, for example, be a sysfs path exposed by the EEPROM device driver) and also the D-Bus object path(s) that EEPROM data needs to be published under.
This parser is can be built by passing in the --enable-ibm-parser
configure option. This parser differs from the OpenPower VPD parser in the following ways:
#
and are > 255 bytes in length).Making the application runtime JSON driven allows us to support multiple systems (with different FRU configurations) to be supported in a single code image as well as making the application more flexible for future improvements.