diff options
author | Andi Kleen <ak@suse.de> | 2008-02-04 10:48:09 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-02-04 10:48:09 -0500 |
commit | d4f71f7969ee2c16e2969185280c13d4f51a9172 (patch) | |
tree | c1f0a7272f0e1ad81213657ebc0062d0d6b66e9a /arch/x86 | |
parent | 7bfb72e847c201fe32271fb13f75d060671d8890 (diff) |
x86: switch direct mapping setup over to set_pte
Use set_pte() for setting up the 2MB pages in the direct mapping.
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/mm/init_64.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c index 5855449ce7aa..3a98d6f724ab 100644 --- a/arch/x86/mm/init_64.c +++ b/arch/x86/mm/init_64.c | |||
@@ -273,7 +273,6 @@ phys_pmd_init(pmd_t *pmd_page, unsigned long address, unsigned long end) | |||
273 | int i = pmd_index(address); | 273 | int i = pmd_index(address); |
274 | 274 | ||
275 | for (; i < PTRS_PER_PMD; i++, address += PMD_SIZE) { | 275 | for (; i < PTRS_PER_PMD; i++, address += PMD_SIZE) { |
276 | unsigned long entry; | ||
277 | pmd_t *pmd = pmd_page + pmd_index(address); | 276 | pmd_t *pmd = pmd_page + pmd_index(address); |
278 | 277 | ||
279 | if (address >= end) { | 278 | if (address >= end) { |
@@ -287,9 +286,8 @@ phys_pmd_init(pmd_t *pmd_page, unsigned long address, unsigned long end) | |||
287 | if (pmd_val(*pmd)) | 286 | if (pmd_val(*pmd)) |
288 | continue; | 287 | continue; |
289 | 288 | ||
290 | entry = __PAGE_KERNEL_LARGE|_PAGE_GLOBAL|address; | 289 | set_pte((pte_t *)pmd, |
291 | entry &= __supported_pte_mask; | 290 | pfn_pte(address >> PAGE_SHIFT, PAGE_KERNEL_LARGE)); |
292 | set_pmd(pmd, __pmd(entry)); | ||
293 | } | 291 | } |
294 | } | 292 | } |
295 | 293 | ||