aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-imx/headsmp.S
diff options
context:
space:
mode:
authorShawn Guo <shawn.guo@linaro.org>2013-04-16 10:11:19 -0400
committerShawn Guo <shawn.guo@linaro.org>2013-05-12 09:39:18 -0400
commit087bb28329f3ccda4e50cb4cf297542d7e773e20 (patch)
tree4654c4ebd9c2417d3f1264d093686f61cfd2c756 /arch/arm/mach-imx/headsmp.S
parent0e574461c4c915a065dd75c894edb653ce99be9c (diff)
ARM: imx: replicate the diagnostic register of boot cpu into secondary cores
The diagnostic register holds the errata bits. Mostly bootloader does not bring up secondary cores, so that when errata bits are set in bootloader, they are set only for boot cpu. But on a SMP configuration, it should be equally done on every single core. Set up the diagnostic register for secondary cores by replicating the register from boot cpu. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
Diffstat (limited to 'arch/arm/mach-imx/headsmp.S')
-rw-r--r--arch/arm/mach-imx/headsmp.S12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/headsmp.S b/arch/arm/mach-imx/headsmp.S
index 67b9c48dcafe..627f16f0e9d1 100644
--- a/arch/arm/mach-imx/headsmp.S
+++ b/arch/arm/mach-imx/headsmp.S
@@ -18,8 +18,20 @@
18 .section ".text.head", "ax" 18 .section ".text.head", "ax"
19 19
20#ifdef CONFIG_SMP 20#ifdef CONFIG_SMP
21diag_reg_offset:
22 .word g_diag_reg - .
23
24 .macro set_diag_reg
25 adr r0, diag_reg_offset
26 ldr r1, [r0]
27 add r1, r1, r0 @ r1 = physical &g_diag_reg
28 ldr r0, [r1]
29 mcr p15, 0, r0, c15, c0, 1 @ write diagnostic register
30 .endm
31
21ENTRY(v7_secondary_startup) 32ENTRY(v7_secondary_startup)
22 bl v7_invalidate_l1 33 bl v7_invalidate_l1
34 set_diag_reg
23 b secondary_startup 35 b secondary_startup
24ENDPROC(v7_secondary_startup) 36ENDPROC(v7_secondary_startup)
25#endif 37#endif