[patch, libgloss] fix redboot-crt0.S for arm7tdmi

Greta Yorsh Greta.Yorsh@arm.com
Tue May 1 16:48:00 GMT 2012


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





More information about the Newlib mailing list