diff options
Diffstat (limited to 'arch/x86/kernel')
| -rw-r--r-- | arch/x86/kernel/acpi/sleep.c | 2 | ||||
| -rw-r--r-- | arch/x86/kernel/e820.c | 21 |
2 files changed, 23 insertions, 0 deletions
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c index 806b4e9051b..707c1f6f95f 100644 --- a/arch/x86/kernel/acpi/sleep.c +++ b/arch/x86/kernel/acpi/sleep.c | |||
| @@ -159,6 +159,8 @@ static int __init acpi_sleep_setup(char *str) | |||
| 159 | #endif | 159 | #endif |
| 160 | if (strncmp(str, "old_ordering", 12) == 0) | 160 | if (strncmp(str, "old_ordering", 12) == 0) |
| 161 | acpi_old_suspend_ordering(); | 161 | acpi_old_suspend_ordering(); |
| 162 | if (strncmp(str, "s4_nonvs", 8) == 0) | ||
| 163 | acpi_s4_no_nvs(); | ||
| 162 | str = strchr(str, ','); | 164 | str = strchr(str, ','); |
| 163 | if (str != NULL) | 165 | if (str != NULL) |
| 164 | str += strspn(str, ", \t"); | 166 | str += strspn(str, ", \t"); |
diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c index 7aafeb5263e..74c6a21fdc8 100644 --- a/arch/x86/kernel/e820.c +++ b/arch/x86/kernel/e820.c | |||
| @@ -665,6 +665,27 @@ void __init e820_mark_nosave_regions(unsigned long limit_pfn) | |||
| 665 | } | 665 | } |
| 666 | #endif | 666 | #endif |
| 667 | 667 | ||
| 668 | #ifdef CONFIG_HIBERNATION | ||
| 669 | /** | ||
| 670 | * Mark ACPI NVS memory region, so that we can save/restore it during | ||
| 671 | * hibernation and the subsequent resume. | ||
| 672 | */ | ||
| 673 | static int __init e820_mark_nvs_memory(void) | ||
| 674 | { | ||
| 675 | int i; | ||
| 676 | |||
| 677 | for (i = 0; i < e820.nr_map; i++) { | ||
| 678 | struct e820entry *ei = &e820.map[i]; | ||
| 679 | |||
| 680 | if (ei->type == E820_NVS) | ||
| 681 | hibernate_nvs_register(ei->addr, ei->size); | ||
| 682 | } | ||
| 683 | |||
| 684 | return 0; | ||
| 685 | } | ||
| 686 | core_initcall(e820_mark_nvs_memory); | ||
| 687 | #endif | ||
| 688 | |||
| 668 | /* | 689 | /* |
| 669 | * Early reserved memory areas. | 690 | * Early reserved memory areas. |
| 670 | */ | 691 | */ |
