diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-07 16:18:13 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-07 16:18:13 -0400 |
commit | e55f1b1c00a2df492fbdaeb3fcba67a45bc82a0e (patch) | |
tree | 96547759d8877fcca6b9b8a1f68066fe5c65b7fd /arch/x86 | |
parent | 27a3b735b70651f28db03e5f92775a40661ba7a6 (diff) | |
parent | f70e957cda22d309c769805cbb932407a5232219 (diff) |
Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86: Don't use the EFI reboot method by default
x86, suspend: Restore MISC_ENABLE MSR in realmode wakeup
x86, reboot: Acer Aspire One A110 reboot quirk
x86-32, NUMA: Fix boot regression caused by NUMA init unification on highmem machines
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/include/asm/mmzone_32.h | 2 | ||||
-rw-r--r-- | arch/x86/kernel/acpi/realmode/wakeup.S | 14 | ||||
-rw-r--r-- | arch/x86/kernel/acpi/realmode/wakeup.h | 6 | ||||
-rw-r--r-- | arch/x86/kernel/acpi/sleep.c | 6 | ||||
-rw-r--r-- | arch/x86/kernel/reboot.c | 8 | ||||
-rw-r--r-- | arch/x86/platform/efi/efi.c | 3 |
6 files changed, 36 insertions, 3 deletions
diff --git a/arch/x86/include/asm/mmzone_32.h b/arch/x86/include/asm/mmzone_32.h index 224e8c5eb307..ffa037f28d39 100644 --- a/arch/x86/include/asm/mmzone_32.h +++ b/arch/x86/include/asm/mmzone_32.h | |||
@@ -57,6 +57,8 @@ static inline int pfn_valid(int pfn) | |||
57 | return 0; | 57 | return 0; |
58 | } | 58 | } |
59 | 59 | ||
60 | #define early_pfn_valid(pfn) pfn_valid((pfn)) | ||
61 | |||
60 | #endif /* CONFIG_DISCONTIGMEM */ | 62 | #endif /* CONFIG_DISCONTIGMEM */ |
61 | 63 | ||
62 | #ifdef CONFIG_NEED_MULTIPLE_NODES | 64 | #ifdef CONFIG_NEED_MULTIPLE_NODES |
diff --git a/arch/x86/kernel/acpi/realmode/wakeup.S b/arch/x86/kernel/acpi/realmode/wakeup.S index ead21b663117..b4fd836e4053 100644 --- a/arch/x86/kernel/acpi/realmode/wakeup.S +++ b/arch/x86/kernel/acpi/realmode/wakeup.S | |||
@@ -28,6 +28,8 @@ pmode_cr3: .long 0 /* Saved %cr3 */ | |||
28 | pmode_cr4: .long 0 /* Saved %cr4 */ | 28 | pmode_cr4: .long 0 /* Saved %cr4 */ |
29 | pmode_efer: .quad 0 /* Saved EFER */ | 29 | pmode_efer: .quad 0 /* Saved EFER */ |
30 | pmode_gdt: .quad 0 | 30 | pmode_gdt: .quad 0 |
31 | pmode_misc_en: .quad 0 /* Saved MISC_ENABLE MSR */ | ||
32 | pmode_behavior: .long 0 /* Wakeup behavior flags */ | ||
31 | realmode_flags: .long 0 | 33 | realmode_flags: .long 0 |
32 | real_magic: .long 0 | 34 | real_magic: .long 0 |
33 | trampoline_segment: .word 0 | 35 | trampoline_segment: .word 0 |
@@ -91,6 +93,18 @@ wakeup_code: | |||
91 | /* Call the C code */ | 93 | /* Call the C code */ |
92 | calll main | 94 | calll main |
93 | 95 | ||
96 | /* Restore MISC_ENABLE before entering protected mode, in case | ||
97 | BIOS decided to clear XD_DISABLE during S3. */ | ||
98 | movl pmode_behavior, %eax | ||
99 | btl $WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE, %eax | ||
100 | jnc 1f | ||
101 | |||
102 | movl pmode_misc_en, %eax | ||
103 | movl pmode_misc_en + 4, %edx | ||
104 | movl $MSR_IA32_MISC_ENABLE, %ecx | ||
105 | wrmsr | ||
106 | 1: | ||
107 | |||
94 | /* Do any other stuff... */ | 108 | /* Do any other stuff... */ |
95 | 109 | ||
96 | #ifndef CONFIG_64BIT | 110 | #ifndef CONFIG_64BIT |
diff --git a/arch/x86/kernel/acpi/realmode/wakeup.h b/arch/x86/kernel/acpi/realmode/wakeup.h index e1828c07e79c..97a29e1430e3 100644 --- a/arch/x86/kernel/acpi/realmode/wakeup.h +++ b/arch/x86/kernel/acpi/realmode/wakeup.h | |||
@@ -21,6 +21,9 @@ struct wakeup_header { | |||
21 | u32 pmode_efer_low; /* Protected mode EFER */ | 21 | u32 pmode_efer_low; /* Protected mode EFER */ |
22 | u32 pmode_efer_high; | 22 | u32 pmode_efer_high; |
23 | u64 pmode_gdt; | 23 | u64 pmode_gdt; |
24 | u32 pmode_misc_en_low; /* Protected mode MISC_ENABLE */ | ||
25 | u32 pmode_misc_en_high; | ||
26 | u32 pmode_behavior; /* Wakeup routine behavior flags */ | ||
24 | u32 realmode_flags; | 27 | u32 realmode_flags; |
25 | u32 real_magic; | 28 | u32 real_magic; |
26 | u16 trampoline_segment; /* segment with trampoline code, 64-bit only */ | 29 | u16 trampoline_segment; /* segment with trampoline code, 64-bit only */ |
@@ -39,4 +42,7 @@ extern struct wakeup_header wakeup_header; | |||
39 | #define WAKEUP_HEADER_SIGNATURE 0x51ee1111 | 42 | #define WAKEUP_HEADER_SIGNATURE 0x51ee1111 |
40 | #define WAKEUP_END_SIGNATURE 0x65a22c82 | 43 | #define WAKEUP_END_SIGNATURE 0x65a22c82 |
41 | 44 | ||
45 | /* Wakeup behavior bits */ | ||
46 | #define WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE 0 | ||
47 | |||
42 | #endif /* ARCH_X86_KERNEL_ACPI_RM_WAKEUP_H */ | 48 | #endif /* ARCH_X86_KERNEL_ACPI_RM_WAKEUP_H */ |
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c index 18a857ba7a25..103b6ab368d3 100644 --- a/arch/x86/kernel/acpi/sleep.c +++ b/arch/x86/kernel/acpi/sleep.c | |||
@@ -77,6 +77,12 @@ int acpi_suspend_lowlevel(void) | |||
77 | 77 | ||
78 | header->pmode_cr0 = read_cr0(); | 78 | header->pmode_cr0 = read_cr0(); |
79 | header->pmode_cr4 = read_cr4_safe(); | 79 | header->pmode_cr4 = read_cr4_safe(); |
80 | header->pmode_behavior = 0; | ||
81 | if (!rdmsr_safe(MSR_IA32_MISC_ENABLE, | ||
82 | &header->pmode_misc_en_low, | ||
83 | &header->pmode_misc_en_high)) | ||
84 | header->pmode_behavior |= | ||
85 | (1 << WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE); | ||
80 | header->realmode_flags = acpi_realmode_flags; | 86 | header->realmode_flags = acpi_realmode_flags; |
81 | header->real_magic = 0x12345678; | 87 | header->real_magic = 0x12345678; |
82 | 88 | ||
diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c index 0c016f727695..4f0d46fefa7f 100644 --- a/arch/x86/kernel/reboot.c +++ b/arch/x86/kernel/reboot.c | |||
@@ -294,6 +294,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = { | |||
294 | DMI_MATCH(DMI_BOARD_NAME, "VersaLogic Menlow board"), | 294 | DMI_MATCH(DMI_BOARD_NAME, "VersaLogic Menlow board"), |
295 | }, | 295 | }, |
296 | }, | 296 | }, |
297 | { /* Handle reboot issue on Acer Aspire one */ | ||
298 | .callback = set_bios_reboot, | ||
299 | .ident = "Acer Aspire One A110", | ||
300 | .matches = { | ||
301 | DMI_MATCH(DMI_SYS_VENDOR, "Acer"), | ||
302 | DMI_MATCH(DMI_PRODUCT_NAME, "AOA110"), | ||
303 | }, | ||
304 | }, | ||
297 | { } | 305 | { } |
298 | }; | 306 | }; |
299 | 307 | ||
diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c index 474356b98ede..899e393d8e73 100644 --- a/arch/x86/platform/efi/efi.c +++ b/arch/x86/platform/efi/efi.c | |||
@@ -504,9 +504,6 @@ void __init efi_init(void) | |||
504 | x86_platform.set_wallclock = efi_set_rtc_mmss; | 504 | x86_platform.set_wallclock = efi_set_rtc_mmss; |
505 | #endif | 505 | #endif |
506 | 506 | ||
507 | /* Setup for EFI runtime service */ | ||
508 | reboot_type = BOOT_EFI; | ||
509 | |||
510 | #if EFI_DEBUG | 507 | #if EFI_DEBUG |
511 | print_efi_memmap(); | 508 | print_efi_memmap(); |
512 | #endif | 509 | #endif |