regs: Handle HUP signals
Enable capturing and handling a HUP signal to reload configuration data.
Tested:
Handler function called upon receiving a SIGHUP
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
Change-Id: I41d136ede5f2a4c0bf595ee58993a4408f153013
diff --git a/phosphor-regulators/src/manager.cpp b/phosphor-regulators/src/manager.cpp
index d7743b7..15071d5 100644
--- a/phosphor-regulators/src/manager.cpp
+++ b/phosphor-regulators/src/manager.cpp
@@ -68,6 +68,12 @@
// collect/update telemetry for each regulator
}
+void Manager::sighupHandler(sdeventplus::source::Signal& /*sigSrc*/,
+ const struct signalfd_siginfo* /*sigInfo*/)
+{
+ // TODO Reload and process the configuration data
+}
+
} // namespace regulators
} // namespace power
} // namespace phosphor