Commit a68823ee authored by Matthew Garrett's avatar Matthew Garrett Committed by Len Brown

ACPI: Clear WAK_STS on resume

The leading other brand OS appears to clear the WAK_STS flag on resume.
When rebooted, certain BIOSes assume that the system is actually
resuming if it's still set and so fail to reboot correctly. Make sure
that it's cleared at resume time.

Comment clarified as suggested by Bob Moore

http://bugzilla.kernel.org/show_bug.cgi?id=11634Signed-off-by: default avatarMatthew Garrett <mjg@redhat.com>
Signed-off-by: default avatarAndi Kleen <ak@linux.intel.com>
Tested-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
Tested-by: default avatarRomano Giannetti <romano.giannetti@gmail.com>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent 3fa8749e
...@@ -627,6 +627,13 @@ acpi_status acpi_leave_sleep_state(u8 sleep_state) ...@@ -627,6 +627,13 @@ acpi_status acpi_leave_sleep_state(u8 sleep_state)
} }
/* TBD: _WAK "sometimes" returns stuff - do we want to look at it? */ /* TBD: _WAK "sometimes" returns stuff - do we want to look at it? */
/*
* Some BIOSes assume that WAK_STS will be cleared on resume and use
* it to determine whether the system is rebooting or resuming. Clear
* it for compatibility.
*/
acpi_set_register(ACPI_BITREG_WAKE_STATUS, 1);
acpi_gbl_system_awake_and_running = TRUE; acpi_gbl_system_awake_and_running = TRUE;
/* Enable power button */ /* Enable power button */
......
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