aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon
diff options
context:
space:
mode:
authorRaag Jadav <raag.jadav@intel.com>2023-10-24 11:50:17 +0530
committerGuenter Roeck <linux@roeck-us.net>2023-10-28 09:21:17 -0700
commit1b515cfee17810e74cda9cf020e302747821d46c (patch)
tree10cf8b8f94ac871bcc4c70ce63f32445beb2d00c /drivers/hwmon
parent62c11e461c7b669e8d42c0e49c8193a5e14d002a (diff)
downloadlinux-1b515cfee17810e74cda9cf020e302747821d46c.tar.gz
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 <raag.jadav@intel.com> Link: https://lore.kernel.org/r/20231024062018.23839-6-raag.jadav@intel.com Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon')
-rw-r--r--drivers/hwmon/nct6775-platform.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/hwmon/nct6775-platform.c b/drivers/hwmon/nct6775-platform.c
index 81bf03dad6bbc5..0adeeab7ee03c0 100644
--- a/drivers/hwmon/nct6775-platform.c
+++ b/drivers/hwmon/nct6775-platform.c
@@ -1465,10 +1465,8 @@ static const char * const asus_msi_boards[] = {
static int nct6775_asuswmi_device_match(struct device *dev, void *data)
{
struct acpi_device *adev = to_acpi_device(dev);
- const char *uid = acpi_device_uid(adev);
- const char *hid = acpi_device_hid(adev);
- if (hid && !strcmp(hid, ASUSWMI_DEVICE_HID) && uid && !strcmp(uid, data)) {
+ if (acpi_dev_hid_uid_match(adev, ASUSWMI_DEVICE_HID, data)) {
asus_acpi_dev = adev;
return 1;
}