When running on armv6, set alignment checking to modulo-4 mode rather

than modulo-8, because clang emits ldrd and strd instructions for
addresses that are only 4-byte aligned
This commit is contained in:
ian 2013-03-31 22:43:16 +00:00
parent fea6d14816
commit f370876f88

View File

@ -27,6 +27,7 @@
*/
#include <machine/asm.h>
#include <machine/armreg.h>
/*
* Entry point to the loader that U-Boot passes control to.
@ -42,6 +43,13 @@ _start:
ldr ip, =saved_regs
str r8, [ip, #0]
#ifdef _ARM_ARCH_6
mrc p15, 0, r2, c1, c0, 0
orr r2, r2, #(CPU_CONTROL_UNAL_ENABLE)
orr r2, r2, #(CPU_CONTROL_AFLT_ENABLE)
mcr p15, 0, r2, c1, c0, 0
#endif
/* Start loader */
b main