diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2015-08-13 16:29:04 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2015-08-13 16:29:04 +0100 |
commit | fd86bdc7a00bb8ed736fff3efe331be2fcdf78ba (patch) | |
tree | f80ba8b934617ce320a1d69c94727209a03e87f4 | |
parent | 9e63052ee30722dc9ce03331092e68b31444970c (diff) |
semihosting tests: enable FPU for system tests
Enable the FPU in the startup code for system emulation tests.
This is necessary for the A64 test in particular and a good
idea for A32/T32.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r-- | start.S | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -27,11 +27,15 @@ .globl start start: # We assume uniprocessor. - # TODO: enable floating point?? #ifndef __aarch64__ # Set up a stack ldr sp, =stacktop + + # Turn on the FPU + mov r0, 0xf00000 + mcr p15, 0, r0, c1, c0, 2 + bl main bl semi_exit # not reached @@ -42,6 +46,11 @@ start: # Set up a stack ldr x0, =stacktop mov sp, x0 + + # Turn on the FPU + mov x0, 0x300000 + msr CPACR_EL1, x0 + bl main bl semi_exit # not reached |