aboutsummaryrefslogtreecommitdiffstats
path: root/os/common/startup/ARM/devices/SAMA5D2/boot.S
diff options
context:
space:
mode:
Diffstat (limited to 'os/common/startup/ARM/devices/SAMA5D2/boot.S')
-rw-r--r--os/common/startup/ARM/devices/SAMA5D2/boot.S3
1 files changed, 2 insertions, 1 deletions
diff --git a/os/common/startup/ARM/devices/SAMA5D2/boot.S b/os/common/startup/ARM/devices/SAMA5D2/boot.S
index 0051c51a8..7aa16face 100644
--- a/os/common/startup/ARM/devices/SAMA5D2/boot.S
+++ b/os/common/startup/ARM/devices/SAMA5D2/boot.S
@@ -49,15 +49,16 @@ Boot_Handler:
*/
ldr r0, =_start
mcr p15, 0, r0, c12, c0, 0
-
/*
* Reset SCTLR Settings
*/
mrc p15, 0, r0, c1, c0, 0 // Read CP15 System Control register
+#if defined(ARM_RESET_SYS_CTRL)
bic r0, r0, #(0x1 << 12) // Clear I bit 12 to disable I Cache
bic r0, r0, #(0x1 << 2) // Clear C bit 2 to disable D Cache
bic r0, r0, #0x1 // Clear M bit 0 to disable MMU
bic r0, r0, #(0x1 << 11) // Clear Z bit 11 to disable branch prediction
+#endif
bic r0, r0, #(0x1 << 13) // Clear V bit 13 to disable hivecs
mcr p15, 0, r0, c1, c0, 0 // Write value back to CP15 System Control register
isb