diff options
author | David Gibson <david@gibson.dropbear.id.au> | 2005-06-21 20:15:31 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-21 21:46:26 -0400 |
commit | 20cee16ced631f70a62c97bdebae08a1c9470448 (patch) | |
tree | f980db4e2b19dfcd4413e6cba4f667eb1d8c79cd /arch/ppc64/kernel | |
parent | 6879dc137ea4efad65cab8bf8a7c0b742bcf92cc (diff) |
[PATCH] ppc64: Abolish ioremap_mm
Currently ppc64 has two mm_structs for the kernel, init_mm and also
ioremap_mm. The latter really isn't necessary: this patch abolishes it,
instead restricting vmallocs to the lower 1TB of the init_mm's range and
placing io mappings in the upper 1TB. This simplifies the code in a number
of places and eliminates an unecessary set of pagetables. It also tweaks
the unmap/free path a little, allowing us to remove the unmap_im_area() set
of page table walkers, replacing them with unmap_vm_area().
Signed-off-by: David Gibson <dwg@au1.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/ppc64/kernel')
-rw-r--r-- | arch/ppc64/kernel/eeh.c | 2 | ||||
-rw-r--r-- | arch/ppc64/kernel/head.S | 4 | ||||
-rw-r--r-- | arch/ppc64/kernel/process.c | 8 |
3 files changed, 1 insertions, 13 deletions
diff --git a/arch/ppc64/kernel/eeh.c b/arch/ppc64/kernel/eeh.c index d63d41f3eecf..af5272fedadf 100644 --- a/arch/ppc64/kernel/eeh.c +++ b/arch/ppc64/kernel/eeh.c | |||
@@ -505,7 +505,7 @@ static inline unsigned long eeh_token_to_phys(unsigned long token) | |||
505 | pte_t *ptep; | 505 | pte_t *ptep; |
506 | unsigned long pa; | 506 | unsigned long pa; |
507 | 507 | ||
508 | ptep = find_linux_pte(ioremap_mm.pgd, token); | 508 | ptep = find_linux_pte(init_mm.pgd, token); |
509 | if (!ptep) | 509 | if (!ptep) |
510 | return token; | 510 | return token; |
511 | pa = pte_pfn(*ptep) << PAGE_SHIFT; | 511 | pa = pte_pfn(*ptep) << PAGE_SHIFT; |
diff --git a/arch/ppc64/kernel/head.S b/arch/ppc64/kernel/head.S index 346dbf606b5d..02c8f4e3e4bc 100644 --- a/arch/ppc64/kernel/head.S +++ b/arch/ppc64/kernel/head.S | |||
@@ -2121,10 +2121,6 @@ empty_zero_page: | |||
2121 | swapper_pg_dir: | 2121 | swapper_pg_dir: |
2122 | .space 4096 | 2122 | .space 4096 |
2123 | 2123 | ||
2124 | .globl ioremap_dir | ||
2125 | ioremap_dir: | ||
2126 | .space 4096 | ||
2127 | |||
2128 | #ifdef CONFIG_SMP | 2124 | #ifdef CONFIG_SMP |
2129 | /* 1 page segment table per cpu (max 48, cpu0 allocated at STAB0_PHYS_ADDR) */ | 2125 | /* 1 page segment table per cpu (max 48, cpu0 allocated at STAB0_PHYS_ADDR) */ |
2130 | .globl stab_array | 2126 | .globl stab_array |
diff --git a/arch/ppc64/kernel/process.c b/arch/ppc64/kernel/process.c index cdfecbeb331f..aba89554d89d 100644 --- a/arch/ppc64/kernel/process.c +++ b/arch/ppc64/kernel/process.c | |||
@@ -58,14 +58,6 @@ struct task_struct *last_task_used_math = NULL; | |||
58 | struct task_struct *last_task_used_altivec = NULL; | 58 | struct task_struct *last_task_used_altivec = NULL; |
59 | #endif | 59 | #endif |
60 | 60 | ||
61 | struct mm_struct ioremap_mm = { | ||
62 | .pgd = ioremap_dir, | ||
63 | .mm_users = ATOMIC_INIT(2), | ||
64 | .mm_count = ATOMIC_INIT(1), | ||
65 | .cpu_vm_mask = CPU_MASK_ALL, | ||
66 | .page_table_lock = SPIN_LOCK_UNLOCKED, | ||
67 | }; | ||
68 | |||
69 | /* | 61 | /* |
70 | * Make sure the floating-point register state in the | 62 | * Make sure the floating-point register state in the |
71 | * the thread_struct is up to date for task tsk. | 63 | * the thread_struct is up to date for task tsk. |