[U-Boot] [PATCH] armv7m: Fix larger builds

Phil Edworthy phil.edworthy at renesas.com
Wed May 24 14:34:26 UTC 2017


The branch instruction only has an 11-bit relative target address, which
is sometimes not enough.

Signed-off-by: Phil Edworthy <phil.edworthy at renesas.com>
---
 arch/arm/cpu/armv7m/start.S | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm/cpu/armv7m/start.S b/arch/arm/cpu/armv7m/start.S
index 49f2720..d79adb5 100644
--- a/arch/arm/cpu/armv7m/start.S
+++ b/arch/arm/cpu/armv7m/start.S
@@ -8,7 +8,8 @@
 .globl	reset
 .type reset, %function
 reset:
-	b	_main
+	ldr	r0, =_main
+	mov	pc, r0
 
 .globl	c_runtime_cpu_setup
 c_runtime_cpu_setup:
-- 
2.7.4



More information about the U-Boot mailing list