pseq: Add generic failure handling to base class
Use the power sequencer base class to handle failure cases where the
device is not found or a device specific failure can not determined. Add
a error logging convience method. Move the D-Bus object to the base
class.
Signed-off-by: Jim Wright <jlwright@us.ibm.com>
Change-Id: I6f7c2951e83cb892ec0c63018d65d5e241ebe6f0
diff --git a/phosphor-power-sequencer/src/power_control.hpp b/phosphor-power-sequencer/src/power_control.hpp
index 1bac68c..5bd5e47 100644
--- a/phosphor-power-sequencer/src/power_control.hpp
+++ b/phosphor-power-sequencer/src/power_control.hpp
@@ -75,8 +75,7 @@
/**
* The power sequencer device to monitor.
*/
- std::unique_ptr<PowerSequencerMonitor> device{
- std::make_unique<PowerSequencerMonitor>()};
+ std::unique_ptr<PowerSequencerMonitor> device;
/**
* Indicates if a specific power sequencer device has already been found.