Skip to content

Commit 84958f3

Browse files
Amadeusz Sławińskirafaeljw
authored andcommitted
x86/ACPI: Preserve ACPI-table override during hibernation
When overriding NHLT ACPI-table tests show that on some platforms there is problem that NHLT contains garbage after hibernation/resume cycle. Problem stems from the fact that ACPI override performs early memory allocation using memblock_phys_alloc_range() in memblock_phys_alloc_range(). This memory block is later being marked as ACPI memory block in arch_reserve_mem_area(). Later when memory areas are considered for hibernation it is being marked as nosave in e820__register_nosave_regions(). Fix this by marking ACPI override memory area as ACPI NVS (Non-Volatile-Sleeping), which according to specification needs to be saved on entering S4 and restored when leaving and is implemented as such in kernel. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 467df4c commit 84958f3

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

arch/x86/kernel/acpi/boot.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1772,7 +1772,7 @@ int __acpi_release_global_lock(unsigned int *lock)
17721772

17731773
void __init arch_reserve_mem_area(acpi_physical_address addr, size_t size)
17741774
{
1775-
e820__range_add(addr, size, E820_TYPE_ACPI);
1775+
e820__range_add(addr, size, E820_TYPE_NVS);
17761776
e820__update_table_print();
17771777
}
17781778

0 commit comments

Comments
 (0)