diff options
Diffstat (limited to 'arch/x86/include/asm')
| -rw-r--r-- | arch/x86/include/asm/amd_nb.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/barrier.h | 8 | ||||
| -rw-r--r-- | arch/x86/include/asm/efi.h | 3 | ||||
| -rw-r--r-- | arch/x86/include/asm/io.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/pgtable.h | 14 | ||||
| -rw-r--r-- | arch/x86/include/asm/spinlock.h | 5 | ||||
| -rw-r--r-- | arch/x86/include/asm/tlbflush.h | 6 | ||||
| -rw-r--r-- | arch/x86/include/asm/tsc.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/xen/page.h | 5 |
9 files changed, 27 insertions, 20 deletions
diff --git a/arch/x86/include/asm/amd_nb.h b/arch/x86/include/asm/amd_nb.h index a54ee1d054d9..aaac3b2fb746 100644 --- a/arch/x86/include/asm/amd_nb.h +++ b/arch/x86/include/asm/amd_nb.h | |||
| @@ -19,7 +19,7 @@ extern int amd_cache_northbridges(void); | |||
| 19 | extern void amd_flush_garts(void); | 19 | extern void amd_flush_garts(void); |
| 20 | extern int amd_numa_init(void); | 20 | extern int amd_numa_init(void); |
| 21 | extern int amd_get_subcaches(int); | 21 | extern int amd_get_subcaches(int); |
| 22 | extern int amd_set_subcaches(int, int); | 22 | extern int amd_set_subcaches(int, unsigned long); |
| 23 | 23 | ||
| 24 | struct amd_l3_cache { | 24 | struct amd_l3_cache { |
| 25 | unsigned indices; | 25 | unsigned indices; |
diff --git a/arch/x86/include/asm/barrier.h b/arch/x86/include/asm/barrier.h index 04a48903b2eb..69bbb4845020 100644 --- a/arch/x86/include/asm/barrier.h +++ b/arch/x86/include/asm/barrier.h | |||
| @@ -85,11 +85,7 @@ | |||
| 85 | #else | 85 | #else |
| 86 | # define smp_rmb() barrier() | 86 | # define smp_rmb() barrier() |
| 87 | #endif | 87 | #endif |
| 88 | #ifdef CONFIG_X86_OOSTORE | 88 | #define smp_wmb() barrier() |
| 89 | # define smp_wmb() wmb() | ||
| 90 | #else | ||
| 91 | # define smp_wmb() barrier() | ||
| 92 | #endif | ||
| 93 | #define smp_read_barrier_depends() read_barrier_depends() | 89 | #define smp_read_barrier_depends() read_barrier_depends() |
| 94 | #define set_mb(var, value) do { (void)xchg(&var, value); } while (0) | 90 | #define set_mb(var, value) do { (void)xchg(&var, value); } while (0) |
| 95 | #else /* !SMP */ | 91 | #else /* !SMP */ |
| @@ -100,7 +96,7 @@ | |||
| 100 | #define set_mb(var, value) do { var = value; barrier(); } while (0) | 96 | #define set_mb(var, value) do { var = value; barrier(); } while (0) |
| 101 | #endif /* SMP */ | 97 | #endif /* SMP */ |
| 102 | 98 | ||
| 103 | #if defined(CONFIG_X86_OOSTORE) || defined(CONFIG_X86_PPRO_FENCE) | 99 | #if defined(CONFIG_X86_PPRO_FENCE) |
| 104 | 100 | ||
| 105 | /* | 101 | /* |
| 106 | * For either of these options x86 doesn't have a strong TSO memory | 102 | * For either of these options x86 doesn't have a strong TSO memory |
diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index 3b978c472d08..acd86c850414 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h | |||
| @@ -132,6 +132,9 @@ extern void __init efi_map_region_fixed(efi_memory_desc_t *md); | |||
| 132 | extern void efi_sync_low_kernel_mappings(void); | 132 | extern void efi_sync_low_kernel_mappings(void); |
| 133 | extern void efi_setup_page_tables(void); | 133 | extern void efi_setup_page_tables(void); |
| 134 | extern void __init old_map_region(efi_memory_desc_t *md); | 134 | extern void __init old_map_region(efi_memory_desc_t *md); |
| 135 | extern void __init runtime_code_page_mkexec(void); | ||
| 136 | extern void __init efi_runtime_mkexec(void); | ||
| 137 | extern void __init efi_apply_memmap_quirks(void); | ||
| 135 | 138 | ||
| 136 | struct efi_setup_data { | 139 | struct efi_setup_data { |
| 137 | u64 fw_vendor; | 140 | u64 fw_vendor; |
diff --git a/arch/x86/include/asm/io.h b/arch/x86/include/asm/io.h index 34f69cb9350a..91d9c69a629e 100644 --- a/arch/x86/include/asm/io.h +++ b/arch/x86/include/asm/io.h | |||
| @@ -237,7 +237,7 @@ memcpy_toio(volatile void __iomem *dst, const void *src, size_t count) | |||
| 237 | 237 | ||
| 238 | static inline void flush_write_buffers(void) | 238 | static inline void flush_write_buffers(void) |
| 239 | { | 239 | { |
| 240 | #if defined(CONFIG_X86_OOSTORE) || defined(CONFIG_X86_PPRO_FENCE) | 240 | #if defined(CONFIG_X86_PPRO_FENCE) |
| 241 | asm volatile("lock; addl $0,0(%%esp)": : :"memory"); | 241 | asm volatile("lock; addl $0,0(%%esp)": : :"memory"); |
| 242 | #endif | 242 | #endif |
| 243 | } | 243 | } |
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index bbc8b12fa443..5ad38ad07890 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h | |||
| @@ -445,10 +445,20 @@ static inline int pte_same(pte_t a, pte_t b) | |||
| 445 | return a.pte == b.pte; | 445 | return a.pte == b.pte; |
| 446 | } | 446 | } |
| 447 | 447 | ||
| 448 | static inline int pteval_present(pteval_t pteval) | ||
| 449 | { | ||
| 450 | /* | ||
| 451 | * Yes Linus, _PAGE_PROTNONE == _PAGE_NUMA. Expressing it this | ||
| 452 | * way clearly states that the intent is that protnone and numa | ||
| 453 | * hinting ptes are considered present for the purposes of | ||
| 454 | * pagetable operations like zapping, protection changes, gup etc. | ||
| 455 | */ | ||
| 456 | return pteval & (_PAGE_PRESENT | _PAGE_PROTNONE | _PAGE_NUMA); | ||
| 457 | } | ||
| 458 | |||
| 448 | static inline int pte_present(pte_t a) | 459 | static inline int pte_present(pte_t a) |
| 449 | { | 460 | { |
| 450 | return pte_flags(a) & (_PAGE_PRESENT | _PAGE_PROTNONE | | 461 | return pteval_present(pte_flags(a)); |
| 451 | _PAGE_NUMA); | ||
| 452 | } | 462 | } |
| 453 | 463 | ||
| 454 | #define pte_accessible pte_accessible | 464 | #define pte_accessible pte_accessible |
diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spinlock.h index bf156ded74b5..0f62f5482d91 100644 --- a/arch/x86/include/asm/spinlock.h +++ b/arch/x86/include/asm/spinlock.h | |||
| @@ -26,10 +26,9 @@ | |||
| 26 | # define LOCK_PTR_REG "D" | 26 | # define LOCK_PTR_REG "D" |
| 27 | #endif | 27 | #endif |
| 28 | 28 | ||
| 29 | #if defined(CONFIG_X86_32) && \ | 29 | #if defined(CONFIG_X86_32) && (defined(CONFIG_X86_PPRO_FENCE)) |
| 30 | (defined(CONFIG_X86_OOSTORE) || defined(CONFIG_X86_PPRO_FENCE)) | ||
| 31 | /* | 30 | /* |
| 32 | * On PPro SMP or if we are using OOSTORE, we use a locked operation to unlock | 31 | * On PPro SMP, we use a locked operation to unlock |
| 33 | * (PPro errata 66, 92) | 32 | * (PPro errata 66, 92) |
| 34 | */ | 33 | */ |
| 35 | # define UNLOCK_LOCK_PREFIX LOCK_PREFIX | 34 | # define UNLOCK_LOCK_PREFIX LOCK_PREFIX |
diff --git a/arch/x86/include/asm/tlbflush.h b/arch/x86/include/asm/tlbflush.h index e6d90babc245..04905bfc508b 100644 --- a/arch/x86/include/asm/tlbflush.h +++ b/arch/x86/include/asm/tlbflush.h | |||
| @@ -62,7 +62,7 @@ static inline void __flush_tlb_all(void) | |||
| 62 | 62 | ||
| 63 | static inline void __flush_tlb_one(unsigned long addr) | 63 | static inline void __flush_tlb_one(unsigned long addr) |
| 64 | { | 64 | { |
| 65 | count_vm_event(NR_TLB_LOCAL_FLUSH_ONE); | 65 | count_vm_tlb_event(NR_TLB_LOCAL_FLUSH_ONE); |
| 66 | __flush_tlb_single(addr); | 66 | __flush_tlb_single(addr); |
| 67 | } | 67 | } |
| 68 | 68 | ||
| @@ -93,13 +93,13 @@ static inline void __flush_tlb_one(unsigned long addr) | |||
| 93 | */ | 93 | */ |
| 94 | static inline void __flush_tlb_up(void) | 94 | static inline void __flush_tlb_up(void) |
| 95 | { | 95 | { |
| 96 | count_vm_event(NR_TLB_LOCAL_FLUSH_ALL); | 96 | count_vm_tlb_event(NR_TLB_LOCAL_FLUSH_ALL); |
| 97 | __flush_tlb(); | 97 | __flush_tlb(); |
| 98 | } | 98 | } |
| 99 | 99 | ||
| 100 | static inline void flush_tlb_all(void) | 100 | static inline void flush_tlb_all(void) |
| 101 | { | 101 | { |
| 102 | count_vm_event(NR_TLB_LOCAL_FLUSH_ALL); | 102 | count_vm_tlb_event(NR_TLB_LOCAL_FLUSH_ALL); |
| 103 | __flush_tlb_all(); | 103 | __flush_tlb_all(); |
| 104 | } | 104 | } |
| 105 | 105 | ||
diff --git a/arch/x86/include/asm/tsc.h b/arch/x86/include/asm/tsc.h index 57ae63cd6ee2..94605c0e9cee 100644 --- a/arch/x86/include/asm/tsc.h +++ b/arch/x86/include/asm/tsc.h | |||
| @@ -66,6 +66,6 @@ extern void tsc_save_sched_clock_state(void); | |||
| 66 | extern void tsc_restore_sched_clock_state(void); | 66 | extern void tsc_restore_sched_clock_state(void); |
| 67 | 67 | ||
| 68 | /* MSR based TSC calibration for Intel Atom SoC platforms */ | 68 | /* MSR based TSC calibration for Intel Atom SoC platforms */ |
| 69 | int try_msr_calibrate_tsc(unsigned long *fast_calibrate); | 69 | unsigned long try_msr_calibrate_tsc(void); |
| 70 | 70 | ||
| 71 | #endif /* _ASM_X86_TSC_H */ | 71 | #endif /* _ASM_X86_TSC_H */ |
diff --git a/arch/x86/include/asm/xen/page.h b/arch/x86/include/asm/xen/page.h index 787e1bb5aafc..3e276eb23d1b 100644 --- a/arch/x86/include/asm/xen/page.h +++ b/arch/x86/include/asm/xen/page.h | |||
| @@ -52,8 +52,7 @@ extern unsigned long set_phys_range_identity(unsigned long pfn_s, | |||
| 52 | extern int m2p_add_override(unsigned long mfn, struct page *page, | 52 | extern int m2p_add_override(unsigned long mfn, struct page *page, |
| 53 | struct gnttab_map_grant_ref *kmap_op); | 53 | struct gnttab_map_grant_ref *kmap_op); |
| 54 | extern int m2p_remove_override(struct page *page, | 54 | extern int m2p_remove_override(struct page *page, |
| 55 | struct gnttab_map_grant_ref *kmap_op, | 55 | struct gnttab_map_grant_ref *kmap_op); |
| 56 | unsigned long mfn); | ||
| 57 | extern struct page *m2p_find_override(unsigned long mfn); | 56 | extern struct page *m2p_find_override(unsigned long mfn); |
| 58 | extern unsigned long m2p_find_override_pfn(unsigned long mfn, unsigned long pfn); | 57 | extern unsigned long m2p_find_override_pfn(unsigned long mfn, unsigned long pfn); |
| 59 | 58 | ||
| @@ -122,7 +121,7 @@ static inline unsigned long mfn_to_pfn(unsigned long mfn) | |||
| 122 | pfn = m2p_find_override_pfn(mfn, ~0); | 121 | pfn = m2p_find_override_pfn(mfn, ~0); |
| 123 | } | 122 | } |
| 124 | 123 | ||
| 125 | /* | 124 | /* |
| 126 | * pfn is ~0 if there are no entries in the m2p for mfn or if the | 125 | * pfn is ~0 if there are no entries in the m2p for mfn or if the |
| 127 | * entry doesn't map back to the mfn and m2p_override doesn't have a | 126 | * entry doesn't map back to the mfn and m2p_override doesn't have a |
| 128 | * valid entry for it. | 127 | * valid entry for it. |
