ACPI: Store NVS state even when entering suspend to RAM
authorMatthew Garrett <mjg@redhat.com>
Fri, 28 May 2010 20:32:15 +0000 (16:32 -0400)
committerLen Brown <len.brown@intel.com>
Thu, 10 Jun 2010 15:03:15 +0000 (11:03 -0400)
commit2a6b69765ad794389f2fc3e14a0afa1a995221c2
tree63c22656f682ba94cdeb882ee370966af57f41c9
parentdd4c4f17d722ffeb2515bf781400675a30fcead7
ACPI: Store NVS state even when entering suspend to RAM

https://bugzilla.kernel.org/show_bug.cgi?id=13931 describes a bug where
a system fails to successfully resume after the second suspend. Maxim
Levitsky discovered that this could be rectified by forcibly saving
and restoring the ACPI non-volatile state. The spec indicates that this
is only required for S4, but testing the behaviour of Windows by adding
an ACPI NVS region to qemu's e820 map and registering a custom memory
read/write handler reveals that it's saved and restored even over suspend
to RAM. We should mimic that behaviour to avoid other broken platforms.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/sleep.c