mirror of
https://github.com/lm-sensors/lm-sensors.git
synced 2026-10-30 13:00:30 +00:00
Add support for dev_name formatted like "a000000.wifi"
This commit is contained in:
1 parent
42f240d2a4
commit
6da486d741
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