aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/kernel')
-rw-r--r--arch/arm/kernel/smp.c36
-rw-r--r--arch/arm/kernel/traps.c12
2 files changed, 6 insertions, 42 deletions
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 5ec79b4ff950..4539ebcb089f 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -55,42 +55,6 @@ enum ipi_msg_type {
55 IPI_CPU_STOP, 55 IPI_CPU_STOP,
56}; 56};
57 57
58static inline void identity_mapping_add(pgd_t *pgd, unsigned long start,
59 unsigned long end)
60{
61 unsigned long addr, prot;
62 pmd_t *pmd;
63
64 prot = PMD_TYPE_SECT | PMD_SECT_AP_WRITE;
65 if (cpu_architecture() <= CPU_ARCH_ARMv5TEJ && !cpu_is_xscale())
66 prot |= PMD_BIT4;
67
68 for (addr = start & PGDIR_MASK; addr < end;) {
69 pmd = pmd_offset(pgd + pgd_index(addr), addr);
70 pmd[0] = __pmd(addr | prot);
71 addr += SECTION_SIZE;
72 pmd[1] = __pmd(addr | prot);
73 addr += SECTION_SIZE;
74 flush_pmd_entry(pmd);
75 outer_clean_range(__pa(pmd), __pa(pmd + 1));
76 }
77}
78
79static inline void identity_mapping_del(pgd_t *pgd, unsigned long start,
80 unsigned long end)
81{
82 unsigned long addr;
83 pmd_t *pmd;
84
85 for (addr = start & PGDIR_MASK; addr < end; addr += PGDIR_SIZE) {
86 pmd = pmd_offset(pgd + pgd_index(addr), addr);
87 pmd[0] = __pmd(0);
88 pmd[1] = __pmd(0);
89 clean_pmd_entry(pmd);
90 outer_clean_range(__pa(pmd), __pa(pmd + 1));
91 }
92}
93
94int __cpuinit __cpu_up(unsigned int cpu) 58int __cpuinit __cpu_up(unsigned int cpu)
95{ 59{
96 struct cpuinfo_arm *ci = &per_cpu(cpu_data, cpu); 60 struct cpuinfo_arm *ci = &per_cpu(cpu_data, cpu);
diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c
index e02f4f7537c5..ee57640ba2bb 100644
--- a/arch/arm/kernel/traps.c
+++ b/arch/arm/kernel/traps.c
@@ -710,19 +710,19 @@ void __readwrite_bug(const char *fn)
710} 710}
711EXPORT_SYMBOL(__readwrite_bug); 711EXPORT_SYMBOL(__readwrite_bug);
712 712
713void __pte_error(const char *file, int line, unsigned long val) 713void __pte_error(const char *file, int line, pte_t pte)
714{ 714{
715 printk("%s:%d: bad pte %08lx.\n", file, line, val); 715 printk("%s:%d: bad pte %08lx.\n", file, line, pte_val(pte));
716} 716}
717 717
718void __pmd_error(const char *file, int line, unsigned long val) 718void __pmd_error(const char *file, int line, pmd_t pmd)
719{ 719{
720 printk("%s:%d: bad pmd %08lx.\n", file, line, val); 720 printk("%s:%d: bad pmd %08lx.\n", file, line, pmd_val(pmd));
721} 721}
722 722
723void __pgd_error(const char *file, int line, unsigned long val) 723void __pgd_error(const char *file, int line, pgd_t pgd)
724{ 724{
725 printk("%s:%d: bad pgd %08lx.\n", file, line, val); 725 printk("%s:%d: bad pgd %08lx.\n", file, line, pgd_val(pgd));
726} 726}
727 727
728asmlinkage void __div0(void) 728asmlinkage void __div0(void)