dimm-spd-reader: fix PMIC type detection from SPD
Add support for identifying PMIC unknown state as 0xFF. Update PMIC SPD detection flow to read SPD registers 0x200, 0x204, and 0x208. Check bit7 to determine whether the PMIC is installed, and use SPD bit[3:0] as the PMIC type. Also update the IPMI error handling path to return completion code 0x07 for command 0x6c when PMIC detection fails or the PMIC type is unknown.
This commit is contained in:
@@ -59,6 +59,8 @@ std::unordered_map<std::string, std::shared_ptr<sdbusplus::asio::dbus_interface>
|
||||
std::unordered_map<std::string, std::shared_ptr<sdbusplus::asio::dbus_interface>> dimm_current_inf;
|
||||
std::unordered_map<std::string, std::shared_ptr<sdbusplus::asio::dbus_interface>> dimm_power_inf;
|
||||
std::unordered_map<std::string, std::shared_ptr<sdbusplus::asio::dbus_interface>> dimm_statusReg_inf;
|
||||
std::unordered_map<std::string, std::shared_ptr<sdbusplus::asio::dbus_interface>> dimm_errCode_inf;
|
||||
|
||||
|
||||
int main()
|
||||
{
|
||||
@@ -177,6 +179,13 @@ int main()
|
||||
dimm_statusReg_inf[dimm]->register_property(
|
||||
"0x0b", uint8_t(0), sdbusplus::asio::PropertyPermission::readWrite);
|
||||
dimm_statusReg_inf[dimm]->initialize();
|
||||
|
||||
dimm_errCode_inf[dimm] = objectServer.add_interface(interfacePath,
|
||||
"xyz.openbmc_project.Dimm.ErrCode");
|
||||
dimm_errCode_inf[dimm]->register_property(
|
||||
"0x32", uint8_t(0), sdbusplus::asio::PropertyPermission::readWrite);
|
||||
dimm_errCode_inf[dimm]->initialize();
|
||||
|
||||
}
|
||||
|
||||
double pollRate = 0.1;
|
||||
|
||||
Reference in New Issue
Block a user