Skip to content

Commit 2c1ada4

Browse files
committed
Merge tag 'acpi-5.1-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull ACPI fix from Rafael Wysocki: "Prevent device references acquired by bus_find_device() in acpi_dev_present() from being leaked (Andy Shevchenko)" * tag 'acpi-5.1-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / utils: Drop reference in test for device presence
2 parents b44290a + 54e3aca commit 2c1ada4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/acpi/utils.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -800,6 +800,7 @@ bool acpi_dev_present(const char *hid, const char *uid, s64 hrv)
800800
match.hrv = hrv;
801801

802802
dev = bus_find_device(&acpi_bus_type, NULL, &match, acpi_dev_match_cb);
803+
put_device(dev);
803804
return !!dev;
804805
}
805806
EXPORT_SYMBOL(acpi_dev_present);

0 commit comments

Comments
 (0)