diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-11 11:23:22 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-11 11:23:22 -0500 |
commit | 9ce04f9238cafcfd09a502f2bc8c13b5f44ec590 (patch) | |
tree | f55b7c0ef48ea5b3bbd2971036ba54b666e8c4ce /arch/x86/include | |
parent | b3f2caaaa82440af06b39c2c92e4fa8122d75465 (diff) | |
parent | 06eb23b1ba39c61ee5d5faeb42a097635693e370 (diff) |
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
ptrace, x86: fix the usage of ptrace_fork()
i8327: fix outb() parameter order
x86: fix math_emu register frame access
x86: math_emu info cleanup
x86: include correct %gs in a.out core dump
x86, vmi: put a missing paravirt_release_pmd in pgd_dtor
x86: find nr_irqs_gsi with mp_ioapic_routing
x86: add clflush before monitor for Intel 7400 series
x86: disable intel_iommu support by default
x86: don't apply __supported_pte_mask to non-present ptes
x86: fix grammar in user-visible BIOS warning
x86/Kconfig.cpu: make Kconfig help readable in the console
x86, 64-bit: print DMI info in the oops trace
Diffstat (limited to 'arch/x86/include')
-rw-r--r-- | arch/x86/include/asm/a.out-core.h | 4 | ||||
-rw-r--r-- | arch/x86/include/asm/cpufeature.h | 1 | ||||
-rw-r--r-- | arch/x86/include/asm/math_emu.h | 29 | ||||
-rw-r--r-- | arch/x86/include/asm/mpspec.h | 6 | ||||
-rw-r--r-- | arch/x86/include/asm/pgtable.h | 26 | ||||
-rw-r--r-- | arch/x86/include/asm/processor.h | 2 | ||||
-rw-r--r-- | arch/x86/include/asm/traps.h | 4 | ||||
-rw-r--r-- | arch/x86/include/asm/xen/page.h | 2 |
8 files changed, 40 insertions, 34 deletions
diff --git a/arch/x86/include/asm/a.out-core.h b/arch/x86/include/asm/a.out-core.h index 37822206083e..3c601f8224be 100644 --- a/arch/x86/include/asm/a.out-core.h +++ b/arch/x86/include/asm/a.out-core.h | |||
@@ -23,8 +23,6 @@ | |||
23 | */ | 23 | */ |
24 | static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) | 24 | static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) |
25 | { | 25 | { |
26 | u16 gs; | ||
27 | |||
28 | /* changed the size calculations - should hopefully work better. lbt */ | 26 | /* changed the size calculations - should hopefully work better. lbt */ |
29 | dump->magic = CMAGIC; | 27 | dump->magic = CMAGIC; |
30 | dump->start_code = 0; | 28 | dump->start_code = 0; |
@@ -57,7 +55,7 @@ static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) | |||
57 | dump->regs.ds = (u16)regs->ds; | 55 | dump->regs.ds = (u16)regs->ds; |
58 | dump->regs.es = (u16)regs->es; | 56 | dump->regs.es = (u16)regs->es; |
59 | dump->regs.fs = (u16)regs->fs; | 57 | dump->regs.fs = (u16)regs->fs; |
60 | savesegment(gs, gs); | 58 | savesegment(gs, dump->regs.gs); |
61 | dump->regs.orig_ax = regs->orig_ax; | 59 | dump->regs.orig_ax = regs->orig_ax; |
62 | dump->regs.ip = regs->ip; | 60 | dump->regs.ip = regs->ip; |
63 | dump->regs.cs = (u16)regs->cs; | 61 | dump->regs.cs = (u16)regs->cs; |
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index ea408dcba513..7301e60dc4a8 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -93,6 +93,7 @@ | |||
93 | #define X86_FEATURE_XTOPOLOGY (3*32+22) /* cpu topology enum extensions */ | 93 | #define X86_FEATURE_XTOPOLOGY (3*32+22) /* cpu topology enum extensions */ |
94 | #define X86_FEATURE_TSC_RELIABLE (3*32+23) /* TSC is known to be reliable */ | 94 | #define X86_FEATURE_TSC_RELIABLE (3*32+23) /* TSC is known to be reliable */ |
95 | #define X86_FEATURE_NONSTOP_TSC (3*32+24) /* TSC does not stop in C states */ | 95 | #define X86_FEATURE_NONSTOP_TSC (3*32+24) /* TSC does not stop in C states */ |
96 | #define X86_FEATURE_CLFLUSH_MONITOR (3*32+25) /* "" clflush reqd with monitor */ | ||
96 | 97 | ||
97 | /* Intel-defined CPU features, CPUID level 0x00000001 (ecx), word 4 */ | 98 | /* Intel-defined CPU features, CPUID level 0x00000001 (ecx), word 4 */ |
98 | #define X86_FEATURE_XMM3 (4*32+ 0) /* "pni" SSE-3 */ | 99 | #define X86_FEATURE_XMM3 (4*32+ 0) /* "pni" SSE-3 */ |
diff --git a/arch/x86/include/asm/math_emu.h b/arch/x86/include/asm/math_emu.h index 5a65b107ad58..031f6266f425 100644 --- a/arch/x86/include/asm/math_emu.h +++ b/arch/x86/include/asm/math_emu.h | |||
@@ -1,31 +1,18 @@ | |||
1 | #ifndef _ASM_X86_MATH_EMU_H | 1 | #ifndef _ASM_X86_MATH_EMU_H |
2 | #define _ASM_X86_MATH_EMU_H | 2 | #define _ASM_X86_MATH_EMU_H |
3 | 3 | ||
4 | #include <asm/ptrace.h> | ||
5 | #include <asm/vm86.h> | ||
6 | |||
4 | /* This structure matches the layout of the data saved to the stack | 7 | /* This structure matches the layout of the data saved to the stack |
5 | following a device-not-present interrupt, part of it saved | 8 | following a device-not-present interrupt, part of it saved |
6 | automatically by the 80386/80486. | 9 | automatically by the 80386/80486. |
7 | */ | 10 | */ |
8 | struct info { | 11 | struct math_emu_info { |
9 | long ___orig_eip; | 12 | long ___orig_eip; |
10 | long ___ebx; | 13 | union { |
11 | long ___ecx; | 14 | struct pt_regs *regs; |
12 | long ___edx; | 15 | struct kernel_vm86_regs *vm86; |
13 | long ___esi; | 16 | }; |
14 | long ___edi; | ||
15 | long ___ebp; | ||
16 | long ___eax; | ||
17 | long ___ds; | ||
18 | long ___es; | ||
19 | long ___fs; | ||
20 | long ___orig_eax; | ||
21 | long ___eip; | ||
22 | long ___cs; | ||
23 | long ___eflags; | ||
24 | long ___esp; | ||
25 | long ___ss; | ||
26 | long ___vm86_es; /* This and the following only in vm86 mode */ | ||
27 | long ___vm86_ds; | ||
28 | long ___vm86_fs; | ||
29 | long ___vm86_gs; | ||
30 | }; | 17 | }; |
31 | #endif /* _ASM_X86_MATH_EMU_H */ | 18 | #endif /* _ASM_X86_MATH_EMU_H */ |
diff --git a/arch/x86/include/asm/mpspec.h b/arch/x86/include/asm/mpspec.h index 62d14ce3cd00..bd22f2a3713f 100644 --- a/arch/x86/include/asm/mpspec.h +++ b/arch/x86/include/asm/mpspec.h | |||
@@ -60,6 +60,7 @@ extern void mp_override_legacy_irq(u8 bus_irq, u8 polarity, u8 trigger, | |||
60 | u32 gsi); | 60 | u32 gsi); |
61 | extern void mp_config_acpi_legacy_irqs(void); | 61 | extern void mp_config_acpi_legacy_irqs(void); |
62 | extern int mp_register_gsi(u32 gsi, int edge_level, int active_high_low); | 62 | extern int mp_register_gsi(u32 gsi, int edge_level, int active_high_low); |
63 | extern int acpi_probe_gsi(void); | ||
63 | #ifdef CONFIG_X86_IO_APIC | 64 | #ifdef CONFIG_X86_IO_APIC |
64 | extern int mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, | 65 | extern int mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, |
65 | u32 gsi, int triggering, int polarity); | 66 | u32 gsi, int triggering, int polarity); |
@@ -71,6 +72,11 @@ mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, | |||
71 | return 0; | 72 | return 0; |
72 | } | 73 | } |
73 | #endif | 74 | #endif |
75 | #else /* !CONFIG_ACPI: */ | ||
76 | static inline int acpi_probe_gsi(void) | ||
77 | { | ||
78 | return 0; | ||
79 | } | ||
74 | #endif /* CONFIG_ACPI */ | 80 | #endif /* CONFIG_ACPI */ |
75 | 81 | ||
76 | #define PHYSID_ARRAY_SIZE BITS_TO_LONGS(MAX_APICS) | 82 | #define PHYSID_ARRAY_SIZE BITS_TO_LONGS(MAX_APICS) |
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index 06bbcbd66e9c..4f5af8447d54 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h | |||
@@ -302,16 +302,30 @@ static inline pte_t pte_mkspecial(pte_t pte) | |||
302 | 302 | ||
303 | extern pteval_t __supported_pte_mask; | 303 | extern pteval_t __supported_pte_mask; |
304 | 304 | ||
305 | /* | ||
306 | * Mask out unsupported bits in a present pgprot. Non-present pgprots | ||
307 | * can use those bits for other purposes, so leave them be. | ||
308 | */ | ||
309 | static inline pgprotval_t massage_pgprot(pgprot_t pgprot) | ||
310 | { | ||
311 | pgprotval_t protval = pgprot_val(pgprot); | ||
312 | |||
313 | if (protval & _PAGE_PRESENT) | ||
314 | protval &= __supported_pte_mask; | ||
315 | |||
316 | return protval; | ||
317 | } | ||
318 | |||
305 | static inline pte_t pfn_pte(unsigned long page_nr, pgprot_t pgprot) | 319 | static inline pte_t pfn_pte(unsigned long page_nr, pgprot_t pgprot) |
306 | { | 320 | { |
307 | return __pte((((phys_addr_t)page_nr << PAGE_SHIFT) | | 321 | return __pte(((phys_addr_t)page_nr << PAGE_SHIFT) | |
308 | pgprot_val(pgprot)) & __supported_pte_mask); | 322 | massage_pgprot(pgprot)); |
309 | } | 323 | } |
310 | 324 | ||
311 | static inline pmd_t pfn_pmd(unsigned long page_nr, pgprot_t pgprot) | 325 | static inline pmd_t pfn_pmd(unsigned long page_nr, pgprot_t pgprot) |
312 | { | 326 | { |
313 | return __pmd((((phys_addr_t)page_nr << PAGE_SHIFT) | | 327 | return __pmd(((phys_addr_t)page_nr << PAGE_SHIFT) | |
314 | pgprot_val(pgprot)) & __supported_pte_mask); | 328 | massage_pgprot(pgprot)); |
315 | } | 329 | } |
316 | 330 | ||
317 | static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) | 331 | static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) |
@@ -323,7 +337,7 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) | |||
323 | * the newprot (if present): | 337 | * the newprot (if present): |
324 | */ | 338 | */ |
325 | val &= _PAGE_CHG_MASK; | 339 | val &= _PAGE_CHG_MASK; |
326 | val |= pgprot_val(newprot) & (~_PAGE_CHG_MASK) & __supported_pte_mask; | 340 | val |= massage_pgprot(newprot) & ~_PAGE_CHG_MASK; |
327 | 341 | ||
328 | return __pte(val); | 342 | return __pte(val); |
329 | } | 343 | } |
@@ -339,7 +353,7 @@ static inline pgprot_t pgprot_modify(pgprot_t oldprot, pgprot_t newprot) | |||
339 | 353 | ||
340 | #define pte_pgprot(x) __pgprot(pte_flags(x) & PTE_FLAGS_MASK) | 354 | #define pte_pgprot(x) __pgprot(pte_flags(x) & PTE_FLAGS_MASK) |
341 | 355 | ||
342 | #define canon_pgprot(p) __pgprot(pgprot_val(p) & __supported_pte_mask) | 356 | #define canon_pgprot(p) __pgprot(massage_pgprot(p)) |
343 | 357 | ||
344 | static inline int is_new_memtype_allowed(unsigned long flags, | 358 | static inline int is_new_memtype_allowed(unsigned long flags, |
345 | unsigned long new_flags) | 359 | unsigned long new_flags) |
diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h index 091cd8855f2e..3bfd5235a9eb 100644 --- a/arch/x86/include/asm/processor.h +++ b/arch/x86/include/asm/processor.h | |||
@@ -353,7 +353,7 @@ struct i387_soft_struct { | |||
353 | u8 no_update; | 353 | u8 no_update; |
354 | u8 rm; | 354 | u8 rm; |
355 | u8 alimit; | 355 | u8 alimit; |
356 | struct info *info; | 356 | struct math_emu_info *info; |
357 | u32 entry_eip; | 357 | u32 entry_eip; |
358 | }; | 358 | }; |
359 | 359 | ||
diff --git a/arch/x86/include/asm/traps.h b/arch/x86/include/asm/traps.h index 2ee0a3bceedf..cf3bb053da0b 100644 --- a/arch/x86/include/asm/traps.h +++ b/arch/x86/include/asm/traps.h | |||
@@ -41,7 +41,7 @@ dotraplinkage void do_int3(struct pt_regs *, long); | |||
41 | dotraplinkage void do_overflow(struct pt_regs *, long); | 41 | dotraplinkage void do_overflow(struct pt_regs *, long); |
42 | dotraplinkage void do_bounds(struct pt_regs *, long); | 42 | dotraplinkage void do_bounds(struct pt_regs *, long); |
43 | dotraplinkage void do_invalid_op(struct pt_regs *, long); | 43 | dotraplinkage void do_invalid_op(struct pt_regs *, long); |
44 | dotraplinkage void do_device_not_available(struct pt_regs *, long); | 44 | dotraplinkage void do_device_not_available(struct pt_regs); |
45 | dotraplinkage void do_coprocessor_segment_overrun(struct pt_regs *, long); | 45 | dotraplinkage void do_coprocessor_segment_overrun(struct pt_regs *, long); |
46 | dotraplinkage void do_invalid_TSS(struct pt_regs *, long); | 46 | dotraplinkage void do_invalid_TSS(struct pt_regs *, long); |
47 | dotraplinkage void do_segment_not_present(struct pt_regs *, long); | 47 | dotraplinkage void do_segment_not_present(struct pt_regs *, long); |
@@ -77,7 +77,7 @@ extern int panic_on_unrecovered_nmi; | |||
77 | extern int kstack_depth_to_print; | 77 | extern int kstack_depth_to_print; |
78 | 78 | ||
79 | void math_error(void __user *); | 79 | void math_error(void __user *); |
80 | asmlinkage void math_emulate(long); | 80 | void math_emulate(struct math_emu_info *); |
81 | #ifdef CONFIG_X86_32 | 81 | #ifdef CONFIG_X86_32 |
82 | unsigned long patch_espfix_desc(unsigned long, unsigned long); | 82 | unsigned long patch_espfix_desc(unsigned long, unsigned long); |
83 | #else | 83 | #else |
diff --git a/arch/x86/include/asm/xen/page.h b/arch/x86/include/asm/xen/page.h index 7ef617ef1df3..4bd990ee43df 100644 --- a/arch/x86/include/asm/xen/page.h +++ b/arch/x86/include/asm/xen/page.h | |||
@@ -137,7 +137,7 @@ static inline pte_t mfn_pte(unsigned long page_nr, pgprot_t pgprot) | |||
137 | pte_t pte; | 137 | pte_t pte; |
138 | 138 | ||
139 | pte.pte = ((phys_addr_t)page_nr << PAGE_SHIFT) | | 139 | pte.pte = ((phys_addr_t)page_nr << PAGE_SHIFT) | |
140 | (pgprot_val(pgprot) & __supported_pte_mask); | 140 | massage_pgprot(pgprot); |
141 | 141 | ||
142 | return pte; | 142 | return pte; |
143 | } | 143 | } |