| Jim Wright | 7945dd2 | 2021-04-06 16:55:15 -0500 | [diff] [blame^] | 1 | #pragma once | 
 | 2 |  | 
 | 3 | #include "pmbus.hpp" | 
 | 4 | #include "power_sequencer_monitor.hpp" | 
 | 5 |  | 
 | 6 | #include <sdbusplus/bus.hpp> | 
 | 7 |  | 
 | 8 | namespace phosphor::power::sequencer | 
 | 9 | { | 
 | 10 |  | 
 | 11 | /** | 
 | 12 |  * @class UCD90320Monitor | 
 | 13 |  * This class implements fault analysis for the UCD90320 | 
 | 14 |  * power sequencer device. | 
 | 15 |  */ | 
 | 16 | class UCD90320Monitor : public PowerSequencerMonitor | 
 | 17 | { | 
 | 18 |   public: | 
 | 19 |     UCD90320Monitor() = delete; | 
 | 20 |     UCD90320Monitor(const UCD90320Monitor&) = delete; | 
 | 21 |     UCD90320Monitor& operator=(const UCD90320Monitor&) = delete; | 
 | 22 |     UCD90320Monitor(UCD90320Monitor&&) = delete; | 
 | 23 |     UCD90320Monitor& operator=(UCD90320Monitor&&) = delete; | 
 | 24 |     virtual ~UCD90320Monitor() = default; | 
 | 25 |  | 
 | 26 |     /** | 
 | 27 |      * Create a device object for UCD90320 monitoring. | 
 | 28 |      * @param[in] bus D-Bus bus object | 
 | 29 |      * @param[in] i2cBus The bus number of the power sequencer device | 
 | 30 |      * @param[in] i2cAddress The I2C address of the power sequencer device | 
 | 31 |      */ | 
 | 32 |     UCD90320Monitor(sdbusplus::bus::bus& bus, std::uint8_t i2cBus, | 
 | 33 |                     const std::uint16_t i2cAddress); | 
 | 34 |  | 
 | 35 |   private: | 
 | 36 |     /** | 
 | 37 |      * The D-Bus bus object | 
 | 38 |      */ | 
 | 39 |     sdbusplus::bus::bus& bus; | 
 | 40 |  | 
 | 41 |     /** | 
 | 42 |      * The read/write interface to this hardware | 
 | 43 |      */ | 
 | 44 |     pmbus::PMBus interface; | 
 | 45 | }; | 
 | 46 |  | 
 | 47 | } // namespace phosphor::power::sequencer |