aboutsummaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorStephen Warren2016-07-18 17:01:50 -0600
committerTom Warren2016-07-21 09:31:30 -0700
commit0e2b5350d9523c9b2dca57b98c89f031691d23e3 (patch)
tree28c2fd3ebfab03eb4cefda1e8928d72325d930dd /arch
parentefbb3d491e87935421242396958fdddd87e0fde1 (diff)
ARM: Add save_boot_params for ARMv8
Implement a hook to allow boards to save boot-time CPU state for later use. When U-Boot is chain-loaded by another bootloader, CPU registers may contain useful information such as system configuration information. This feature mirrors the equivalent ARMv7 feature. Signed-off-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Tom Rini <trini@konsulko.com> Signed-off-by: Tom Warren <twarren@nvidia.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/cpu/armv8/start.S9
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv8/start.S b/arch/arm/cpu/armv8/start.S
index 67edf94520c..19c771dba3a 100644
--- a/arch/arm/cpu/armv8/start.S
+++ b/arch/arm/cpu/armv8/start.S
@@ -53,6 +53,11 @@ _bss_end_ofs:
.quad __bss_end - _start
reset:
+ /* Allow the board to save important registers */
+ b save_boot_params
+.globl save_boot_params_ret
+save_boot_params_ret:
+
#ifdef CONFIG_SYS_RESET_SCTRL
bl reset_sctrl
#endif
@@ -282,3 +287,7 @@ ENTRY(c_runtime_cpu_setup)
ret
ENDPROC(c_runtime_cpu_setup)
+
+WEAK(save_boot_params)
+ b save_boot_params_ret /* back to my caller */
+ENDPROC(save_boot_params)