diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-08 16:06:15 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-08 16:06:15 -0700 |
commit | a38133298fc678335a0229e97b6161a7ac6fec84 (patch) | |
tree | 2500f23fd230e67a8eba96b380245ecb43c3fd4c /arch/ia64/mm/init.c | |
parent | 97d26b8042a6f14cc4a19e84e911a953363e3d69 (diff) | |
parent | 70aa488cff83c965c9e1850f48d82b000d0d6c1c (diff) | |
download | kernel_samsung_smdk4412-a38133298fc678335a0229e97b6161a7ac6fec84.zip kernel_samsung_smdk4412-a38133298fc678335a0229e97b6161a7ac6fec84.tar.gz kernel_samsung_smdk4412-a38133298fc678335a0229e97b6161a7ac6fec84.tar.bz2 |
Merge rsync://rsync.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6
Diffstat (limited to 'arch/ia64/mm/init.c')
-rw-r--r-- | arch/ia64/mm/init.c | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c index 547785e..4eb2f52 100644 --- a/arch/ia64/mm/init.c +++ b/arch/ia64/mm/init.c @@ -305,8 +305,9 @@ setup_gate (void) struct page *page; /* - * Map the gate page twice: once read-only to export the ELF headers etc. and once - * execute-only page to enable privilege-promotion via "epc": + * Map the gate page twice: once read-only to export the ELF + * headers etc. and once execute-only page to enable + * privilege-promotion via "epc": */ page = virt_to_page(ia64_imva(__start_gate_section)); put_kernel_page(page, GATE_ADDR, PAGE_READONLY); @@ -315,6 +316,20 @@ setup_gate (void) put_kernel_page(page, GATE_ADDR + PAGE_SIZE, PAGE_GATE); #else put_kernel_page(page, GATE_ADDR + PERCPU_PAGE_SIZE, PAGE_GATE); + /* Fill in the holes (if any) with read-only zero pages: */ + { + unsigned long addr; + + for (addr = GATE_ADDR + PAGE_SIZE; + addr < GATE_ADDR + PERCPU_PAGE_SIZE; + addr += PAGE_SIZE) + { + put_kernel_page(ZERO_PAGE(0), addr, + PAGE_READONLY); + put_kernel_page(ZERO_PAGE(0), addr + PERCPU_PAGE_SIZE, + PAGE_READONLY); + } + } #endif ia64_patch_gate(); } |