Skip to content

Commit 1b515cf

Browse files
raagjadavgroeck
authored andcommitted
hwmon: (nct6775) use acpi_dev_hid_uid_match() for matching _HID and _UID
Convert manual _UID references to use the standard ACPI helper. Signed-off-by: Raag Jadav <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
1 parent 62c11e4 commit 1b515cf

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

drivers/hwmon/nct6775-platform.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1465,10 +1465,8 @@ static const char * const asus_msi_boards[] = {
14651465
static int nct6775_asuswmi_device_match(struct device *dev, void *data)
14661466
{
14671467
struct acpi_device *adev = to_acpi_device(dev);
1468-
const char *uid = acpi_device_uid(adev);
1469-
const char *hid = acpi_device_hid(adev);
14701468

1471-
if (hid && !strcmp(hid, ASUSWMI_DEVICE_HID) && uid && !strcmp(uid, data)) {
1469+
if (acpi_dev_hid_uid_match(adev, ASUSWMI_DEVICE_HID, data)) {
14721470
asus_acpi_dev = adev;
14731471
return 1;
14741472
}

0 commit comments

Comments
 (0)