aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2010-02-12 09:36:24 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-03-14 15:42:35 -0400
commit1027247f6eb727db6c600b9eb02796f0766ae704 (patch)
tree5ed53827e63426a5a2358cced2e20c4fdfc20970 /arch/arm
parentd10fca9f39238b07cc670b441d2b423de30359d2 (diff)
ARM: Add L2 cache handling to smp boot support
The page table and secondary data which we're asking the secondary CPU to make use of has to hit RAM to ensure that the secondary CPU can see it since it may not be taking part in coherency or cache searches at this point. Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/kernel/smp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 57162af53dc..577543f3857 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -99,6 +99,7 @@ int __cpuinit __cpu_up(unsigned int cpu)
99 *pmd = __pmd((PHYS_OFFSET & PGDIR_MASK) | 99 *pmd = __pmd((PHYS_OFFSET & PGDIR_MASK) |
100 PMD_TYPE_SECT | PMD_SECT_AP_WRITE); 100 PMD_TYPE_SECT | PMD_SECT_AP_WRITE);
101 flush_pmd_entry(pmd); 101 flush_pmd_entry(pmd);
102 outer_clean_range(__pa(pmd), __pa(pmd + 1));
102 103
103 /* 104 /*
104 * We need to tell the secondary core where to find 105 * We need to tell the secondary core where to find
@@ -106,7 +107,8 @@ int __cpuinit __cpu_up(unsigned int cpu)
106 */ 107 */
107 secondary_data.stack = task_stack_page(idle) + THREAD_START_SP; 108 secondary_data.stack = task_stack_page(idle) + THREAD_START_SP;
108 secondary_data.pgdir = virt_to_phys(pgd); 109 secondary_data.pgdir = virt_to_phys(pgd);
109 wmb(); 110 __cpuc_flush_dcache_area(&secondary_data, sizeof(secondary_data));
111 outer_clean_range(__pa(&secondary_data), __pa(&secondary_data + 1));
110 112
111 /* 113 /*
112 * Now bring the CPU into our world. 114 * Now bring the CPU into our world.