commit | 6ad74d9f369884f5ae4c40301c2c01a2ece33105 | [log] [tgz] |
---|---|---|
author | Matt Spinler <spinler@us.ibm.com> | Tue Mar 01 10:56:46 2022 -0600 |
committer | Ed Tanous <ed@tanous.net> | Tue Mar 08 15:48:12 2022 +0000 |
tree | e41b780806bab4f9188bbdd58a2cb6a6745602eb | |
parent | 5431c49ac5cb48b21534ab651182cacec1c75a6c [diff] |
adc: Only process CPUReq sensors when CPUs change The adcsensor application watches for the Present property to change on CPUs so that it can check if any ADC sensors that have the 'CPURequired' configuration field need changes. However, in this case it was also deleting and recreating non-CPU related sensors, such as ones that measure the RTC battery voltage. This is a problem because if that sensor is below threshold, it will behave as if the threshold were newly asserted by emitting propertiesChanged signals on the threshold alarm properties as well as emitting the ThresholdAsserted signals again. Fix this by changing the code to only process sensors that have the CPURequired field when handling CPU presence changes. Tested: Check D-Bus signals when CPU presence changes versus when a threshold configuration property changes and see the expected handling. Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I8f00726e71c85e70203a5cb6ee5dd99b4fe9e9c1
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