[lm-sensors] [PATCH 1/4] libsensors: Detect OpenFirmware hwmon devices
Darrick J. Wong
djwong at us.ibm.com
Tue Apr 1 01:49:32 CEST 2008
On a QS22 blade, the BMC containing the (ibmpex) power meters is enumerated
via Open Firmware. Check for "of_platform" to handle this case.
Signed-off-by: Darrick J. Wong <djwong at us.ibm.com>
Index: lm-sensors-3.0.0/lib/sysfs.c
===================================================================
--- lm-sensors-3.0.0.orig/lib/sysfs.c 2008-03-31 16:08:07.000000000 -0700
+++ lm-sensors-3.0.0/lib/sysfs.c 2008-03-31 16:08:14.000000000 -0700
@@ -532,7 +532,8 @@
entry.chip.bus.type = SENSORS_BUS_TYPE_PCI;
entry.chip.bus.nr = 0;
} else
- if ((!subsys || !strcmp(subsys, "platform"))) {
+ if ((!subsys || !strcmp(subsys, "platform") ||
+ !strcmp(subsys, "of_platform"))) {
/* must be new ISA (platform driver) */
if (sscanf(dev_name, "%*[a-z0-9_].%d", &entry.chip.addr) != 1)
entry.chip.addr = 0;
More information about the lm-sensors
mailing list