PSUSensor: Add support for MAX16601 and add label temp6
Tested: Combined with related driver, related entity-manager changes and
related config file changes, sensors properly show up in IPMI sensors.
Change-Id: Id1c1e4ede11b69fefbd806a1d5c496bf4aaf1b88
Signed-off-by: Alex Qiu <xqiu@google.com>
diff --git a/src/PSUSensorMain.cpp b/src/PSUSensorMain.cpp
index 64f54da..19286f6 100644
--- a/src/PSUSensorMain.cpp
+++ b/src/PSUSensorMain.cpp
@@ -39,9 +39,10 @@
static constexpr bool DEBUG = false;
-static constexpr std::array<const char*, 7> sensorTypes = {
+static constexpr std::array<const char*, 8> sensorTypes = {
"xyz.openbmc_project.Configuration.INA230",
"xyz.openbmc_project.Configuration.ISL68137",
+ "xyz.openbmc_project.Configuration.MAX16601",
"xyz.openbmc_project.Configuration.MAX20730",
"xyz.openbmc_project.Configuration.MAX20734",
"xyz.openbmc_project.Configuration.MAX20796",
@@ -49,8 +50,8 @@
"xyz.openbmc_project.Configuration.pmbus"};
static std::vector<std::string> pmbusNames = {
- "isl68137", "ina219", "ina230", "max20730", "max20734",
- "max20796", "max34451", "pmbus", "pxe1610"};
+ "isl68137", "ina219", "ina230", "max16601", "max20730",
+ "max20734", "max20796", "max34451", "pmbus", "pxe1610"};
namespace fs = std::filesystem;
@@ -811,6 +812,7 @@
{"temp3", PSUProperty("Temperature", 127, -128, 3)},
{"temp4", PSUProperty("Temperature", 127, -128, 3)},
{"temp5", PSUProperty("Temperature", 127, -128, 3)},
+ {"temp6", PSUProperty("Temperature", 127, -128, 3)},
{"fan1", PSUProperty("Fan Speed 1", 30000, 0, 0)},
{"fan2", PSUProperty("Fan Speed 2", 30000, 0, 0)}};