diff options
author | Alison Wang <b18965@freescale.com> | 2016-11-10 10:49:03 +0800 |
---|---|---|
committer | York Sun <york.sun@nxp.com> | 2016-11-22 11:40:24 -0800 |
commit | ec6617c39741adc6c54952564579e32c3c09c66f (patch) | |
tree | 2c65fb7ab999e39eb6acc0be8890eced30c950a1 /arch/arm/cpu/armv8/start.S | |
parent | 95e74a3df75bf01eaf69f5c28f9aa2db6568e901 (diff) | |
download | u-boot-ec6617c39741adc6c54952564579e32c3c09c66f.tar.gz u-boot-ec6617c39741adc6c54952564579e32c3c09c66f.tar.xz u-boot-ec6617c39741adc6c54952564579e32c3c09c66f.zip |
armv8: Support loading 32-bit OS in AArch32 execution state
To support loading a 32-bit OS, the execution state will change from
AArch64 to AArch32 when jumping to kernel.
The architecture information will be got through checking FIT image,
then U-Boot will load 32-bit OS or 64-bit OS automatically.
Signed-off-by: Ebony Zhu <ebony.zhu@nxp.com>
Signed-off-by: Alison Wang <alison.wang@nxp.com>
Signed-off-by: Chenhui Zhao <chenhui.zhao@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
Diffstat (limited to 'arch/arm/cpu/armv8/start.S')
-rw-r--r-- | arch/arm/cpu/armv8/start.S | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv8/start.S b/arch/arm/cpu/armv8/start.S index 19c771dba3..4f5f6d8020 100644 --- a/arch/arm/cpu/armv8/start.S +++ b/arch/arm/cpu/armv8/start.S @@ -251,9 +251,17 @@ WEAK(lowlevel_init) /* * All slaves will enter EL2 and optionally EL1. */ + adr x3, lowlevel_in_el2 + ldr x4, =ES_TO_AARCH64 bl armv8_switch_to_el2 + +lowlevel_in_el2: #ifdef CONFIG_ARMV8_SWITCH_TO_EL1 + adr x3, lowlevel_in_el1 + ldr x4, =ES_TO_AARCH64 bl armv8_switch_to_el1 + +lowlevel_in_el1: #endif #endif /* CONFIG_ARMV8_MULTIENTRY */ |