diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-07-18 16:50:34 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-18 16:50:34 -0400 |
commit | a208f37a465e222218974ab20a31b42b7b4893b2 (patch) | |
tree | 77c6acdd4be32024330a14f2618b814126ce7a20 /arch/x86/kernel/acpi | |
parent | 511d9d34183662aada3890883e860b151d707e22 (diff) | |
parent | 5b664cb235e97afbf34db9c4d77f08ebd725335e (diff) |
Merge branch 'linus' into x86/x2apic
Diffstat (limited to 'arch/x86/kernel/acpi')
-rw-r--r-- | arch/x86/kernel/acpi/boot.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/acpi/processor.c | 6 | ||||
-rw-r--r-- | arch/x86/kernel/acpi/sleep.c | 32 |
3 files changed, 32 insertions, 7 deletions
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index b314bcd08406..b41b27af33e6 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c | |||
@@ -1411,7 +1411,6 @@ static int __init dmi_ignore_irq0_timer_override(const struct dmi_system_id *d) | |||
1411 | { | 1411 | { |
1412 | pr_notice("%s detected: Ignoring BIOS IRQ0 pin2 override\n", d->ident); | 1412 | pr_notice("%s detected: Ignoring BIOS IRQ0 pin2 override\n", d->ident); |
1413 | acpi_skip_timer_override = 1; | 1413 | acpi_skip_timer_override = 1; |
1414 | force_mask_ioapic_irq_2(); | ||
1415 | return 0; | 1414 | return 0; |
1416 | } | 1415 | } |
1417 | 1416 | ||
diff --git a/arch/x86/kernel/acpi/processor.c b/arch/x86/kernel/acpi/processor.c index de2d2e4ebad9..7c074eec39fb 100644 --- a/arch/x86/kernel/acpi/processor.c +++ b/arch/x86/kernel/acpi/processor.c | |||
@@ -56,6 +56,12 @@ static void init_intel_pdc(struct acpi_processor *pr, struct cpuinfo_x86 *c) | |||
56 | if (cpu_has(c, X86_FEATURE_ACPI)) | 56 | if (cpu_has(c, X86_FEATURE_ACPI)) |
57 | buf[2] |= ACPI_PDC_T_FFH; | 57 | buf[2] |= ACPI_PDC_T_FFH; |
58 | 58 | ||
59 | /* | ||
60 | * If mwait/monitor is unsupported, C2/C3_FFH will be disabled | ||
61 | */ | ||
62 | if (!cpu_has(c, X86_FEATURE_MWAIT)) | ||
63 | buf[2] &= ~(ACPI_PDC_C_C2C3_FFH); | ||
64 | |||
59 | obj->type = ACPI_TYPE_BUFFER; | 65 | obj->type = ACPI_TYPE_BUFFER; |
60 | obj->buffer.length = 12; | 66 | obj->buffer.length = 12; |
61 | obj->buffer.pointer = (u8 *) buf; | 67 | obj->buffer.pointer = (u8 *) buf; |
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c index e6a4b564ccaa..868de3d5c39d 100644 --- a/arch/x86/kernel/acpi/sleep.c +++ b/arch/x86/kernel/acpi/sleep.c | |||
@@ -23,6 +23,15 @@ static unsigned long acpi_realmode; | |||
23 | static char temp_stack[10240]; | 23 | static char temp_stack[10240]; |
24 | #endif | 24 | #endif |
25 | 25 | ||
26 | /* XXX: this macro should move to asm-x86/segment.h and be shared with the | ||
27 | boot code... */ | ||
28 | #define GDT_ENTRY(flags, base, limit) \ | ||
29 | (((u64)(base & 0xff000000) << 32) | \ | ||
30 | ((u64)flags << 40) | \ | ||
31 | ((u64)(limit & 0x00ff0000) << 32) | \ | ||
32 | ((u64)(base & 0x00ffffff) << 16) | \ | ||
33 | ((u64)(limit & 0x0000ffff))) | ||
34 | |||
26 | /** | 35 | /** |
27 | * acpi_save_state_mem - save kernel state | 36 | * acpi_save_state_mem - save kernel state |
28 | * | 37 | * |
@@ -51,18 +60,27 @@ int acpi_save_state_mem(void) | |||
51 | header->video_mode = saved_video_mode; | 60 | header->video_mode = saved_video_mode; |
52 | 61 | ||
53 | header->wakeup_jmp_seg = acpi_wakeup_address >> 4; | 62 | header->wakeup_jmp_seg = acpi_wakeup_address >> 4; |
63 | |||
64 | /* | ||
65 | * Set up the wakeup GDT. We set these up as Big Real Mode, | ||
66 | * that is, with limits set to 4 GB. At least the Lenovo | ||
67 | * Thinkpad X61 is known to need this for the video BIOS | ||
68 | * initialization quirk to work; this is likely to also | ||
69 | * be the case for other laptops or integrated video devices. | ||
70 | */ | ||
71 | |||
54 | /* GDT[0]: GDT self-pointer */ | 72 | /* GDT[0]: GDT self-pointer */ |
55 | header->wakeup_gdt[0] = | 73 | header->wakeup_gdt[0] = |
56 | (u64)(sizeof(header->wakeup_gdt) - 1) + | 74 | (u64)(sizeof(header->wakeup_gdt) - 1) + |
57 | ((u64)(acpi_wakeup_address + | 75 | ((u64)(acpi_wakeup_address + |
58 | ((char *)&header->wakeup_gdt - (char *)acpi_realmode)) | 76 | ((char *)&header->wakeup_gdt - (char *)acpi_realmode)) |
59 | << 16); | 77 | << 16); |
60 | /* GDT[1]: real-mode-like code segment */ | 78 | /* GDT[1]: big real mode-like code segment */ |
61 | header->wakeup_gdt[1] = (0x009bULL << 40) + | 79 | header->wakeup_gdt[1] = |
62 | ((u64)acpi_wakeup_address << 16) + 0xffff; | 80 | GDT_ENTRY(0x809b, acpi_wakeup_address, 0xfffff); |
63 | /* GDT[2]: real-mode-like data segment */ | 81 | /* GDT[2]: big real mode-like data segment */ |
64 | header->wakeup_gdt[2] = (0x0093ULL << 40) + | 82 | header->wakeup_gdt[2] = |
65 | ((u64)acpi_wakeup_address << 16) + 0xffff; | 83 | GDT_ENTRY(0x8093, acpi_wakeup_address, 0xfffff); |
66 | 84 | ||
67 | #ifndef CONFIG_64BIT | 85 | #ifndef CONFIG_64BIT |
68 | store_gdt((struct desc_ptr *)&header->pmode_gdt); | 86 | store_gdt((struct desc_ptr *)&header->pmode_gdt); |
@@ -140,6 +158,8 @@ static int __init acpi_sleep_setup(char *str) | |||
140 | acpi_realmode_flags |= 2; | 158 | acpi_realmode_flags |= 2; |
141 | if (strncmp(str, "s3_beep", 7) == 0) | 159 | if (strncmp(str, "s3_beep", 7) == 0) |
142 | acpi_realmode_flags |= 4; | 160 | acpi_realmode_flags |= 4; |
161 | if (strncmp(str, "old_ordering", 12) == 0) | ||
162 | acpi_old_suspend_ordering(); | ||
143 | str = strchr(str, ','); | 163 | str = strchr(str, ','); |
144 | if (str != NULL) | 164 | if (str != NULL) |
145 | str += strspn(str, ", \t"); | 165 | str += strspn(str, ", \t"); |