瀏覽代碼

armv8: move reset branch into boot hook

The boot0 hook we have so far is applied _after_ the initial branch
to the "reset" entry point. An upcoming change requires even this
branch to be changed, so we apply the hook macro at the earliest
point, and have the branch in the hook file as well.
This is no functional change at this point, just refactoring to simplify
upcoming patches.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jagan Teki <jagan@openedev.com>
Andre Przywara 8 年之前
父節點
當前提交
a5168a5900
共有 2 個文件被更改,包括 3 次插入2 次删除
  1. 2 2
      arch/arm/cpu/armv8/start.S
  2. 1 0
      arch/arm/include/asm/arch-sunxi/boot0.h

+ 2 - 2
arch/arm/cpu/armv8/start.S

@@ -19,8 +19,6 @@
 
 
 .globl	_start
 .globl	_start
 _start:
 _start:
-	b	reset
-
 #ifdef CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK
 #ifdef CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK
 /*
 /*
  * Various SoCs need something special and SoC-specific up front in
  * Various SoCs need something special and SoC-specific up front in
@@ -29,6 +27,8 @@ _start:
  */
  */
 #include <asm/arch/boot0.h>
 #include <asm/arch/boot0.h>
 ARM_SOC_BOOT0_HOOK
 ARM_SOC_BOOT0_HOOK
+#else
+	b	reset
 #endif
 #endif
 
 
 	.align 3
 	.align 3

+ 1 - 0
arch/arm/include/asm/arch-sunxi/boot0.h

@@ -9,6 +9,7 @@
 
 
 /* reserve space for BOOT0 header information */
 /* reserve space for BOOT0 header information */
 #define ARM_SOC_BOOT0_HOOK	\
 #define ARM_SOC_BOOT0_HOOK	\
+	b	reset;		\
 	.space	1532
 	.space	1532
 
 
 #endif /* __BOOT0_H */
 #endif /* __BOOT0_H */