Skip to content
Snippets Groups Projects
Commit 9b7ff25d authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

ACPI: power: Refine turning off unused power resources

Commit 7e4fdeaf ("ACPI: power: Turn off unused power resources
unconditionally") dropped the power resource state check from
acpi_turn_off_unused_power_resources(), because according to the
ACPI specification (e.g. ACPI 6.4, Section 7.2.2) the OS "may run
the _OFF method repeatedly, even if the resource is already off".

However, it turns out that some systems do not follow the
specification in this particular respect and that commit introduced
boot issues on them, so refine acpi_turn_off_unused_power_resources()
to only turn off power resources without any users after device
enumeration and restore its previous behavior in the system-wide
resume path.

Fixes: 7e4fdeaf ("ACPI: power: Turn off unused power resources unconditionally")
Link: https://uefi.org/specs/ACPI/6.4/07_Power_and_Performance_Mgmt/declaring-a-power-resource-object.html#off
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=213019


Reported-by: default avatarZhang Rui <rui.zhang@intel.com>
Tested-by: default avatarZhang Rui <rui.zhang@intel.com>
Reported-by: default avatarDave Olsthoorn <dave@bewaar.me>
Tested-by: default avatarDave Olsthoorn <dave@bewaar.me>
Reported-by: default avatarShujun Wang <wsj20369@163.com>
Tested-by: default avatarShujun Wang <wsj20369@163.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent c4681547
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment