regulators: Add Services& services to classes
Modify the configure() method in the System, Chassis, Device, and Rail
classes to have a new first parameter: Services& services.
Fix mock_services.hpp bug.
Signed-off-by: Bob King <Bob_King@wistron.com>
Change-Id: I6ef41de65d2c5b68c55edb42189ba9c0f2e436ed
diff --git a/phosphor-regulators/src/chassis.cpp b/phosphor-regulators/src/chassis.cpp
index 29ebb79..ebe446c 100644
--- a/phosphor-regulators/src/chassis.cpp
+++ b/phosphor-regulators/src/chassis.cpp
@@ -43,7 +43,7 @@
}
}
-void Chassis::configure(System& system)
+void Chassis::configure(Services& services, System& system)
{
// Log info message in journal; important for verifying success of boot
journal::logInfo("Configuring chassis " + std::to_string(number));
@@ -51,7 +51,7 @@
// Configure devices
for (std::unique_ptr<Device>& device : devices)
{
- device->configure(system, *this);
+ device->configure(services, system, *this);
}
}