diff options
Diffstat (limited to 'drivers/acpi/sleep.c')
-rw-r--r-- | drivers/acpi/sleep.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c index b718806657cd..b0f6c4a2a119 100644 --- a/drivers/acpi/sleep.c +++ b/drivers/acpi/sleep.c | |||
@@ -807,7 +807,12 @@ int __init acpi_sleep_init(void) | |||
807 | acpi_sleep_hibernate_setup(); | 807 | acpi_sleep_hibernate_setup(); |
808 | 808 | ||
809 | status = acpi_get_sleep_type_data(ACPI_STATE_S5, &type_a, &type_b); | 809 | status = acpi_get_sleep_type_data(ACPI_STATE_S5, &type_a, &type_b); |
810 | if (ACPI_SUCCESS(status)) { | 810 | /* |
811 | * Check both ACPI S5 object and ACPI sleep registers to | ||
812 | * install pm_power_off_prepare/pm_power_off hook | ||
813 | */ | ||
814 | if (ACPI_SUCCESS(status) && acpi_gbl_FADT.sleep_control.address | ||
815 | && acpi_gbl_FADT.sleep_status.address) { | ||
811 | sleep_states[ACPI_STATE_S5] = 1; | 816 | sleep_states[ACPI_STATE_S5] = 1; |
812 | pm_power_off_prepare = acpi_power_off_prepare; | 817 | pm_power_off_prepare = acpi_power_off_prepare; |
813 | pm_power_off = acpi_power_off; | 818 | pm_power_off = acpi_power_off; |