mirror of
https://github.com/lm-sensors/lm-sensors.git
synced 2026-10-28 12:40:42 +00:00
Merge pull request 'Add support for dev_name formatted like "a000000.wifi"' (#410) from 7217043955/master into master
Reviewed-on: http://localhost:8888/hramrach/lm-sensors/pulls/410
This commit is contained in:
commit
9b1a3974bb
1 file changed
+3
-2
+3
-2
@@ -663,8 +663,9 @@ static int classify_device(const char *dev_name,
|
||||
if ((!subsys || !strcmp(subsys, "platform") ||
|
||||
!strcmp(subsys, "of_platform"))) {
|
||||
/* must be new ISA (platform driver) */
|
||||
if (sscanf(dev_name, "%*[a-zA-Z0-9_]%*1[.:]%d", &entry->chip.addr) != 1)
|
||||
entry->chip.addr = 0;
|
||||
if (sscanf(dev_name, "%*[a-zA-Z0-9_]%*1[.:]%d", &entry->chip.addr) == 1);
|
||||
else if (sscanf(dev_name, "%x.%*s", &entry->chip.addr) == 1);
|
||||
else entry->chip.addr = 0;
|
||||
entry->chip.bus.type = SENSORS_BUS_TYPE_ISA;
|
||||
entry->chip.bus.nr = 0;
|
||||
} else if (subsys && !strcmp(subsys, "acpi")) {
|
||||
|
||||
Reference in new issue
Block a user