Commit 927002ed authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'acpi-5.11-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull ACPI fix from Rafael Wysocki:
 "Address recent regression causing battery devices to be never bound to
  a driver on some systems (Hans de Goede)"

* tag 'acpi-5.11-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ACPI: scan: Fix battery devices sometimes never binding
parents 4cb2c00c 0f347aa0
......@@ -2123,12 +2123,12 @@ void acpi_walk_dep_device_list(acpi_handle handle)
list_for_each_entry_safe(dep, tmp, &acpi_dep_list, node) {
if (dep->supplier == handle) {
acpi_bus_get_device(dep->consumer, &adev);
if (!adev)
continue;
adev->dep_unmet--;
if (!adev->dep_unmet)
acpi_bus_attach(adev, true);
if (adev) {
adev->dep_unmet--;
if (!adev->dep_unmet)
acpi_bus_attach(adev, true);
}
list_del(&dep->node);
kfree(dep);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment