aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ppc/mm/pgtable.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ppc/mm/pgtable.c')
-rw-r--r--arch/ppc/mm/pgtable.c28
1 files changed, 0 insertions, 28 deletions
diff --git a/arch/ppc/mm/pgtable.c b/arch/ppc/mm/pgtable.c
index 1f51e6c94507..fadacfd18806 100644
--- a/arch/ppc/mm/pgtable.c
+++ b/arch/ppc/mm/pgtable.c
@@ -42,10 +42,6 @@ int io_bat_index;
42#define HAVE_BATS 1 42#define HAVE_BATS 1
43#endif 43#endif
44 44
45#if defined(CONFIG_FSL_BOOKE)
46#define HAVE_TLBCAM 1
47#endif
48
49extern char etext[], _stext[]; 45extern char etext[], _stext[];
50 46
51#ifdef CONFIG_SMP 47#ifdef CONFIG_SMP
@@ -63,15 +59,6 @@ void setbat(int index, unsigned long virt, unsigned long phys,
63#define p_mapped_by_bats(x) (0UL) 59#define p_mapped_by_bats(x) (0UL)
64#endif /* HAVE_BATS */ 60#endif /* HAVE_BATS */
65 61
66#ifdef HAVE_TLBCAM
67extern unsigned int tlbcam_index;
68extern unsigned long v_mapped_by_tlbcam(unsigned long va);
69extern unsigned long p_mapped_by_tlbcam(unsigned long pa);
70#else /* !HAVE_TLBCAM */
71#define v_mapped_by_tlbcam(x) (0UL)
72#define p_mapped_by_tlbcam(x) (0UL)
73#endif /* HAVE_TLBCAM */
74
75#ifdef CONFIG_PTE_64BIT 62#ifdef CONFIG_PTE_64BIT
76/* 44x uses an 8kB pgdir because it has 8-byte Linux PTEs. */ 63/* 44x uses an 8kB pgdir because it has 8-byte Linux PTEs. */
77#define PGDIR_ORDER 1 64#define PGDIR_ORDER 1
@@ -213,9 +200,6 @@ __ioremap(phys_addr_t addr, unsigned long size, unsigned long flags)
213 if ((v = p_mapped_by_bats(p)) /*&& p_mapped_by_bats(p+size-1)*/ ) 200 if ((v = p_mapped_by_bats(p)) /*&& p_mapped_by_bats(p+size-1)*/ )
214 goto out; 201 goto out;
215 202
216 if ((v = p_mapped_by_tlbcam(p)))
217 goto out;
218
219 if (mem_init_done) { 203 if (mem_init_done) {
220 struct vm_struct *area; 204 struct vm_struct *area;
221 area = get_vm_area(size, VM_IOREMAP); 205 area = get_vm_area(size, VM_IOREMAP);
@@ -341,18 +325,6 @@ void __init io_block_mapping(unsigned long virt, phys_addr_t phys,
341 } 325 }
342#endif /* HAVE_BATS */ 326#endif /* HAVE_BATS */
343 327
344#ifdef HAVE_TLBCAM
345 /*
346 * Use a CAM for this if possible...
347 */
348 if (tlbcam_index < num_tlbcam_entries && is_power_of_4(size)
349 && (virt & (size - 1)) == 0 && (phys & (size - 1)) == 0) {
350 settlbcam(tlbcam_index, virt, phys, size, flags, 0);
351 ++tlbcam_index;
352 return;
353 }
354#endif /* HAVE_TLBCAM */
355
356 /* No BATs available, put it in the page tables. */ 328 /* No BATs available, put it in the page tables. */
357 for (i = 0; i < size; i += PAGE_SIZE) 329 for (i = 0; i < size; i += PAGE_SIZE)
358 map_page(virt + i, phys + i, flags); 330 map_page(virt + i, phys + i, flags);