regulators: Modify monitorSensors() to use Services
Modify the monitorSensors() method in the System, Chassis, Device, and
Rail classes to have a new first parameter: Services& services.
Modify SensorMonitoring::execute() to log messages using the new
Journal interface.
Signed-off-by: Bob King <Bob_King@wistron.com>
Change-Id: I05820cfa94bc3d15dee7a1714a3d253720aa7f92
diff --git a/phosphor-regulators/src/device.cpp b/phosphor-regulators/src/device.cpp
index f085afe..df73d1a 100644
--- a/phosphor-regulators/src/device.cpp
+++ b/phosphor-regulators/src/device.cpp
@@ -73,13 +73,14 @@
}
}
-void Device::monitorSensors(System& system, Chassis& chassis)
+void Device::monitorSensors(Services& services, System& system,
+ Chassis& chassis)
{
// Monitor sensors in each rail
for (std::unique_ptr<Rail>& rail : rails)
{
- rail->monitorSensors(system, chassis, *this);
+ rail->monitorSensors(services, system, chassis, *this);
}
}