summaryrefslogtreecommitdiffstats
path: root/mainloop.cpp
diff options
context:
space:
mode:
authorPatrick Venture <venture@google.com>2018-04-20 18:10:15 -0700
committerPatrick Venture <venture@google.com>2018-04-24 20:46:07 +0000
commit75e56c67a10e9f4c617f9c72a87deb695322e212 (patch)
tree1cdef89f2efa1fc89c7dc737e00d39b51d92317a /mainloop.cpp
parent609fe98205fe8f4bd0dc6b9fca66877e2edf186d (diff)
downloadphosphor-hwmon-75e56c67a10e9f4c617f9c72a87deb695322e212.tar.gz
phosphor-hwmon-75e56c67a10e9f4c617f9c72a87deb695322e212.zip
hwmonio: split IoAccess object out
Split out the hwmon io access object from the sysfs namespace into its own. Change-Id: I8d1a45630117d1d503d0d5fa6061163911b695e8 Signed-off-by: Patrick Venture <venture@google.com>
Diffstat (limited to 'mainloop.cpp')
-rw-r--r--mainloop.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/mainloop.cpp b/mainloop.cpp
index 4c74f53..5324fcd 100644
--- a/mainloop.cpp
+++ b/mainloop.cpp
@@ -27,6 +27,7 @@
#include "fan_pwm.hpp"
#include "fan_speed.hpp"
#include "hwmon.hpp"
+#include "hwmonio.hpp"
#include "sensorset.hpp"
#include "sysfs.hpp"
#include "mainloop.hpp"
@@ -132,7 +133,7 @@ int64_t adjustValue(const SensorSet::key_type& sensor, int64_t value)
auto addValue(const SensorSet::key_type& sensor,
const RetryIO& retryIO,
- sysfs::hwmonio::HwmonIO& ioAccess,
+ hwmonio::HwmonIO& ioAccess,
ObjectInfo& info,
bool isOCC = false)
{
@@ -278,7 +279,7 @@ void MainLoop::getObject(SensorSet::container_t::const_reference sensor)
objectPath.append(std::get<sensorLabel>(properties));
ObjectInfo info(&_bus, std::move(objectPath), Object());
- RetryIO retryIO(sysfs::hwmonio::retries, sysfs::hwmonio::delay);
+ RetryIO retryIO(hwmonio::retries, hwmonio::delay);
if (rmSensors.find(sensor.first) != rmSensors.end())
{
// When adding a sensor that was purposely removed,
@@ -507,8 +508,8 @@ void MainLoop::read()
i.first.first,
i.first.second,
input,
- sysfs::hwmonio::retries,
- sysfs::hwmonio::delay,
+ hwmonio::retries,
+ hwmonio::delay,
_isOCC);
value = adjustValue(i.first, value);
OpenPOWER on IntegriCloud