commit | db76d49cf7740500db4e677046a9175e0b3f173e | [log] [tgz] |
---|---|---|
author | Brandon Kim <brandonkim@google.com> | Mon Jun 17 11:53:04 2019 -0700 |
committer | Brandon Kim <brandonkim@google.com> | Tue Jun 18 10:27:45 2019 -0700 |
tree | 0e7457c4754ba3302c98f5d5f41c44a1f349072d | |
parent | d0ce7925d77c56c142f64b2c6ae55f0020c06ba8 [diff] |
sensor: Implement RAII object for GPIO unlock and lock There is a bug where GPIO lock may not be called if there is an exception after GPIO unlock. Adding an RAII object for GPIO lock and replacing the current usage of gpioUnlock, gpioLock in sensor.cpp and mainloop.cpp. Bug: openbmc/phosphor-hwmon#11 Signed-off-by: Brandon Kim <brandonkim@google.com> Change-Id: Ica094e716a6ff9dc99165651f83fc496d5ed5a17
Exposes generic hwmon entries as DBus objects. More information can be found at Sensor Architecture
To build this package, do the following steps: 1. ./bootstrap.sh 2. ./configure ${CONFIGURE_FLAGS} 3. make To clean the repository run `./bootstrap.sh clean`.
To enable the use of Linux features like cgroups prioritization and udev/systemd control, one instance of phosphor-hwmon is intended to be run per hwmon sysfs class instance. This requires an algorithm for selecting a stable, well-known D-Bus busname. The algorithm is <PREFIX>-<ID>.Hwmon<N> where PREFIX is an autoconf configurable prefix (BUSNAME_PREFIX, xyz.openbmc_project by default), ID is a std::hash of the /sys/devices path backing the hwmon class instance, and N is the implemented phosphor-hwmon D-Bus API version.