This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
[patch, libgloss] fix redboot-crt0.S for arm7tdmi
- From: "Greta Yorsh" <Greta dot Yorsh at arm dot com>
- To: <newlib at sourceware dot org>
- Cc: <nickc at redhat dot com>
- Date: Fri, 27 Apr 2012 11:41:11 +0100
- Subject: [patch, libgloss] fix redboot-crt0.S for arm7tdmi
Building libgloss/arm/redboot-crt0.S for arm7tdmi in thumb mode fails,
because it uses "MOV a2 a3".
The use of MOV with two low registers is not supported in thumb mode in
architectures prior to ARMv6.
This patch replaces MOV with MOVS.
2012-04-26 Greta Yorsh <Greta.Yorsh@arm.com>
* arm/redboot-crt0.S (__change_mode): Replace mov with movs.
diff --git a/libgloss/arm/redboot-crt0.S b/libgloss/arm/redboot-crt0.S
index dcd042c..88eb60d 100644
--- a/libgloss/arm/redboot-crt0.S
+++ b/libgloss/arm/redboot-crt0.S
@@ -97,7 +97,7 @@ __change_mode:
movs a1, #0
ldr a2, .LC3
- mov a3, a2
+ movs a3, a2
bl SYM_NAME(main)
1: bl SYM_NAME(exit)
b 1b