commit | e3e3c97af854f702523efef70c9bf6a660b2099f | [log] [tgz] |
---|---|---|
author | Andrew Jeffery <andrew@aj.id.au> | Wed May 26 14:37:07 2021 +0930 |
committer | Andrew Jeffery <andrew@aj.id.au> | Thu Sep 23 22:30:11 2021 +0000 |
tree | 43e4158e42a47d68517e3bce0963292fce9fcad0 | |
parent | e3b23c06d4dd61ad29978f9abb719a7af0c84353 [diff] |
nvmesensor: Support the NVMe MI basic management command The NVMe MI basic management command is an optional extension to the NVMe specification that allows management controllers to query drive state without needing an MCTP stack[1]. [1] https://nvmexpress.org/wp-content/uploads/NVMe_Management_-_Technical_Note_on_Basic_Management_Command.pdf Given the current lack of support for the SMBus MCTP binding in upstream OpenBMC, provide an NVMe MI basic management command implementation that allows nvmesensor to function without diving into a maze of out-of-tree patches. As we're doing this in userspace we exploit Linux's I2C chardev interface for talking to the drives. However, the interface is driven by ioctl()s, which interacts poorly with the event-driven ASIO design. Click the lego together by using an IO thread to transform ioctl()s into read() and write() operations that we can handle asynchronously. Change-Id: I08cca4991a2ddea23fe8fcc1cf5365d4baded11c Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
dbus-sensors is a collection of sensor applications that provide the xyz.openbmc_project.Sensor collection of interfaces. They read sensor values from hwmon, d-bus, or direct driver access to provide readings. Some advance non-sensor features such as fan presence, pwm control, and automatic cpu detection (x86) are also supported.
runtime re-configurable from d-bus (entity-manager or the like)
isolated: each sensor type is isolated into its own daemon, so a bug in one sensor is unlikely to affect another, and single sensor modifications are possible
async single-threaded: uses sdbusplus/asio bindings
multiple data inputs: hwmon, d-bus, direct driver access