fru: use ipmifruproperty for property lookup
The member IPMIFruData::property was unused and instead the property
lookup was performed with the phosphor-dbus-interface property name.
The IPMIFruData::property field is meant to map from dbus property to
FRU property to allow a variety of dbus mappings.
Tested: Verified the member was unused.
Tested: Verified that a configuration yaml mapping is respected and
ipmid will report the information expected given a FRU published to
dbus.
Note: The fields for IPMI FRU properties were taken from the example
YAML and are expected to be what was used by machines leveraging this
feature.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I44f73b67ecdeae2d772daa38cc21cc18cdf9c7ce
diff --git a/read_fru_data.cpp b/read_fru_data.cpp
index 1a1949d..327f552 100644
--- a/read_fru_data.cpp
+++ b/read_fru_data.cpp
@@ -138,8 +138,9 @@
if (iter != allProp.end())
{
data[properties.second.section].emplace(
- properties.first, std::move(std::get<std::string>(
- allProp[properties.first])));
+ properties.second.property,
+ std::move(
+ std::get<std::string>(allProp[properties.first])));
}
}
}