diff options
author | Haavard Skinnemoen <haavard.skinnemoen@atmel.com> | 2008-01-14 16:15:05 -0500 |
---|---|---|
committer | Haavard Skinnemoen <haavard.skinnemoen@atmel.com> | 2008-07-02 05:01:28 -0400 |
commit | cfd23e93a0289cf6711fd3877c5226658d87240a (patch) | |
tree | 1030f0ee5ccd59d1d80b2b5fdc892987f90fac8e /arch/avr32/mm | |
parent | ebe74597a55fef00edc80a414ef5c6477d035e0a (diff) |
avr32: Store virtual addresses in the PGD
Instead of storing physical addresses along with page flags in the
PGD, store virtual addresses and use NULL to indicate a not present
second-level page table. A non-page-aligned page table indicates a bad
PMD.
This simplifies the TLB miss handler since it no longer has to check
the Present bit and no longer has to convert the PGD entry from
physical to virtual address. Instead, it has to check for a NULL
entry, which is slightly cheaper than either.
Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
Diffstat (limited to 'arch/avr32/mm')
-rw-r--r-- | arch/avr32/mm/init.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/avr32/mm/init.c b/arch/avr32/mm/init.c index 0e77578c358d..3f90a87527bb 100644 --- a/arch/avr32/mm/init.c +++ b/arch/avr32/mm/init.c | |||
@@ -24,9 +24,11 @@ | |||
24 | #include <asm/setup.h> | 24 | #include <asm/setup.h> |
25 | #include <asm/sections.h> | 25 | #include <asm/sections.h> |
26 | 26 | ||
27 | #define __page_aligned __attribute__((section(".data.page_aligned"))) | ||
28 | |||
27 | DEFINE_PER_CPU(struct mmu_gather, mmu_gathers); | 29 | DEFINE_PER_CPU(struct mmu_gather, mmu_gathers); |
28 | 30 | ||
29 | pgd_t swapper_pg_dir[PTRS_PER_PGD]; | 31 | pgd_t swapper_pg_dir[PTRS_PER_PGD] __page_aligned; |
30 | 32 | ||
31 | struct page *empty_zero_page; | 33 | struct page *empty_zero_page; |
32 | EXPORT_SYMBOL(empty_zero_page); | 34 | EXPORT_SYMBOL(empty_zero_page); |