diff options
author | David Gibson <david@gibson.dropbear.id.au> | 2005-11-15 23:43:48 -0500 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-11-18 22:46:02 -0500 |
commit | 800fc3eeb0eed3bf98d621c0da24d68cabcf6526 (patch) | |
tree | 23f80f2be4f4fb186505b7d95b0335f6afe37ecd /arch/powerpc | |
parent | 0e6850f615af510c992ff9753f4d8c385969a17c (diff) |
[PATCH] powerpc: Remove imalloc.h
asm-ppc64/imalloc.h is only included from files in arch/powerpc/mm.
We already have a header for mm local definitions,
arch/powerpc/mm/mmu_decl.h. Thus, this patch moves the contents of
imalloc.h into mmu_decl.h. The only exception are the definitions of
PHBS_IO_BASE, IMALLOC_BASE and IMALLOC_END. Those are moved into
pgtable.h, next to similar definitions of VMALLOC_START and
VMALLOC_SIZE.
Built for multiplatform 32bit and 64bit (ARCH=powerpc).
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc')
-rw-r--r-- | arch/powerpc/mm/imalloc.c | 3 | ||||
-rw-r--r-- | arch/powerpc/mm/init_64.c | 3 | ||||
-rw-r--r-- | arch/powerpc/mm/mmu_decl.h | 14 | ||||
-rw-r--r-- | arch/powerpc/mm/pgtable_64.c | 3 |
4 files changed, 19 insertions, 4 deletions
diff --git a/arch/powerpc/mm/imalloc.c b/arch/powerpc/mm/imalloc.c index f4ca29cf5364..f9587bcc6a48 100644 --- a/arch/powerpc/mm/imalloc.c +++ b/arch/powerpc/mm/imalloc.c | |||
@@ -14,9 +14,10 @@ | |||
14 | #include <asm/pgalloc.h> | 14 | #include <asm/pgalloc.h> |
15 | #include <asm/pgtable.h> | 15 | #include <asm/pgtable.h> |
16 | #include <asm/semaphore.h> | 16 | #include <asm/semaphore.h> |
17 | #include <asm/imalloc.h> | ||
18 | #include <asm/cacheflush.h> | 17 | #include <asm/cacheflush.h> |
19 | 18 | ||
19 | #include "mmu_decl.h" | ||
20 | |||
20 | static DECLARE_MUTEX(imlist_sem); | 21 | static DECLARE_MUTEX(imlist_sem); |
21 | struct vm_struct * imlist = NULL; | 22 | struct vm_struct * imlist = NULL; |
22 | 23 | ||
diff --git a/arch/powerpc/mm/init_64.c b/arch/powerpc/mm/init_64.c index 1134f70f231d..81cfb0c2ec58 100644 --- a/arch/powerpc/mm/init_64.c +++ b/arch/powerpc/mm/init_64.c | |||
@@ -64,7 +64,8 @@ | |||
64 | #include <asm/iommu.h> | 64 | #include <asm/iommu.h> |
65 | #include <asm/abs_addr.h> | 65 | #include <asm/abs_addr.h> |
66 | #include <asm/vdso.h> | 66 | #include <asm/vdso.h> |
67 | #include <asm/imalloc.h> | 67 | |
68 | #include "mmu_decl.h" | ||
68 | 69 | ||
69 | #ifdef DEBUG | 70 | #ifdef DEBUG |
70 | #define DBG(fmt...) printk(fmt) | 71 | #define DBG(fmt...) printk(fmt) |
diff --git a/arch/powerpc/mm/mmu_decl.h b/arch/powerpc/mm/mmu_decl.h index a4d7a327c0e5..bea2d21ac6f7 100644 --- a/arch/powerpc/mm/mmu_decl.h +++ b/arch/powerpc/mm/mmu_decl.h | |||
@@ -33,7 +33,6 @@ extern void invalidate_tlbcam_entry(int index); | |||
33 | 33 | ||
34 | extern int __map_without_bats; | 34 | extern int __map_without_bats; |
35 | extern unsigned long ioremap_base; | 35 | extern unsigned long ioremap_base; |
36 | extern unsigned long ioremap_bot; | ||
37 | extern unsigned int rtas_data, rtas_size; | 36 | extern unsigned int rtas_data, rtas_size; |
38 | 37 | ||
39 | extern PTE *Hash, *Hash_end; | 38 | extern PTE *Hash, *Hash_end; |
@@ -42,6 +41,7 @@ extern unsigned long Hash_size, Hash_mask; | |||
42 | extern unsigned int num_tlbcam_entries; | 41 | extern unsigned int num_tlbcam_entries; |
43 | #endif | 42 | #endif |
44 | 43 | ||
44 | extern unsigned long ioremap_bot; | ||
45 | extern unsigned long __max_low_memory; | 45 | extern unsigned long __max_low_memory; |
46 | extern unsigned long __initial_memory_limit; | 46 | extern unsigned long __initial_memory_limit; |
47 | extern unsigned long total_memory; | 47 | extern unsigned long total_memory; |
@@ -84,4 +84,16 @@ static inline void flush_HPTE(unsigned context, unsigned long va, | |||
84 | else | 84 | else |
85 | _tlbie(va); | 85 | _tlbie(va); |
86 | } | 86 | } |
87 | #else /* CONFIG_PPC64 */ | ||
88 | /* imalloc region types */ | ||
89 | #define IM_REGION_UNUSED 0x1 | ||
90 | #define IM_REGION_SUBSET 0x2 | ||
91 | #define IM_REGION_EXISTS 0x4 | ||
92 | #define IM_REGION_OVERLAP 0x8 | ||
93 | #define IM_REGION_SUPERSET 0x10 | ||
94 | |||
95 | extern struct vm_struct * im_get_free_area(unsigned long size); | ||
96 | extern struct vm_struct * im_get_area(unsigned long v_addr, unsigned long size, | ||
97 | int region_type); | ||
98 | extern void im_free(void *addr); | ||
87 | #endif | 99 | #endif |
diff --git a/arch/powerpc/mm/pgtable_64.c b/arch/powerpc/mm/pgtable_64.c index c7f7bb6f30b3..2ffca63602c5 100644 --- a/arch/powerpc/mm/pgtable_64.c +++ b/arch/powerpc/mm/pgtable_64.c | |||
@@ -64,7 +64,8 @@ | |||
64 | #include <asm/iommu.h> | 64 | #include <asm/iommu.h> |
65 | #include <asm/abs_addr.h> | 65 | #include <asm/abs_addr.h> |
66 | #include <asm/vdso.h> | 66 | #include <asm/vdso.h> |
67 | #include <asm/imalloc.h> | 67 | |
68 | #include "mmu_decl.h" | ||
68 | 69 | ||
69 | unsigned long ioremap_bot = IMALLOC_BASE; | 70 | unsigned long ioremap_bot = IMALLOC_BASE; |
70 | static unsigned long phbs_io_bot = PHBS_IO_BASE; | 71 | static unsigned long phbs_io_bot = PHBS_IO_BASE; |