diff options
author | Jeremy Fitzhardinge <jeremy@goop.org> | 2008-07-01 19:46:36 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-08 07:16:29 -0400 |
commit | ef5e94af16c0c82452e1ea5d387e1203dd2198d6 (patch) | |
tree | 7d80d1bba8a0c58e91995ead6f8b2cd6eddd314e /include | |
parent | 8490638cf0fb3975f7636c5268f27d5daf4eaaa5 (diff) |
x86_32: remove __PAGE_KERNEL(_EXEC)
From: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Older x86-32 processors do not support global mappings (PGD), so must
only use it if the processor supports it.
The _PAGE_KERNEL* flags always have _PAGE_KERNEL set, since logically
we always want it set.
This is OK even on processors which do not support PGD, since all
_PAGE flags are masked with __supported_pte_mask before being turned
into a real in-pagetable pte. On 32-bit systems, __supported_pte_mask
is initialized to not contain _PAGE_GLOBAL, and it is then added if
the CPU is found to support it.
The x86-32 code used to use __PAGE_KERNEL/__PAGE_KERNEL_EXEC for this
purpose, but they're now redundant and can be removed.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Cc: Stephen Tweedie <sct@redhat.com>
Cc: Eduardo Habkost <ehabkost@redhat.com>
Cc: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-x86/pgtable.h | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/include/asm-x86/pgtable.h b/include/asm-x86/pgtable.h index a1c0009e81b7..64de07e25329 100644 --- a/include/asm-x86/pgtable.h +++ b/include/asm-x86/pgtable.h | |||
@@ -78,19 +78,9 @@ | |||
78 | #define PAGE_READONLY_EXEC __pgprot(_PAGE_PRESENT | _PAGE_USER | \ | 78 | #define PAGE_READONLY_EXEC __pgprot(_PAGE_PRESENT | _PAGE_USER | \ |
79 | _PAGE_ACCESSED) | 79 | _PAGE_ACCESSED) |
80 | 80 | ||
81 | #ifdef CONFIG_X86_32 | ||
82 | #define _PAGE_KERNEL_EXEC \ | ||
83 | (_PAGE_PRESENT | _PAGE_RW | _PAGE_DIRTY | _PAGE_ACCESSED) | ||
84 | #define _PAGE_KERNEL (_PAGE_KERNEL_EXEC | _PAGE_NX) | ||
85 | |||
86 | #ifndef __ASSEMBLY__ | ||
87 | extern pteval_t __PAGE_KERNEL, __PAGE_KERNEL_EXEC; | ||
88 | #endif /* __ASSEMBLY__ */ | ||
89 | #else | ||
90 | #define __PAGE_KERNEL_EXEC \ | 81 | #define __PAGE_KERNEL_EXEC \ |
91 | (_PAGE_PRESENT | _PAGE_RW | _PAGE_DIRTY | _PAGE_ACCESSED | _PAGE_GLOBAL) | 82 | (_PAGE_PRESENT | _PAGE_RW | _PAGE_DIRTY | _PAGE_ACCESSED | _PAGE_GLOBAL) |
92 | #define __PAGE_KERNEL (__PAGE_KERNEL_EXEC | _PAGE_NX) | 83 | #define __PAGE_KERNEL (__PAGE_KERNEL_EXEC | _PAGE_NX) |
93 | #endif | ||
94 | 84 | ||
95 | #define __PAGE_KERNEL_RO (__PAGE_KERNEL & ~_PAGE_RW) | 85 | #define __PAGE_KERNEL_RO (__PAGE_KERNEL & ~_PAGE_RW) |
96 | #define __PAGE_KERNEL_RX (__PAGE_KERNEL_EXEC & ~_PAGE_RW) | 86 | #define __PAGE_KERNEL_RX (__PAGE_KERNEL_EXEC & ~_PAGE_RW) |