Skip to contentSkip to conversation

arm: use canonical sub mnemonic

PATCH New Andreas Bießmann 2 participants 4 messages Nov 27, 2013 – Jan 14, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm: use canonical sub mnemonic

Building some arm boards with older binutils may produce errors like this:

---8<---
crt0.S: Assembler messages:
crt0.S:70: Error: register expected, not '#(184)' -- `sub sp,#(184)' --->8---

Use canonical version of the subtract mnemonic to avoid those issues.

---

 arch/arm/cpu/armv7/lowlevel_init.S |    2 +-
 arch/arm/lib/crt0.S                |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +1 -1
index 69e3053..f1aea05 100644
@@ -24,7 +24,7 @@ ENTRY(lowlevel_init)
 #ifdef CONFIG_SPL_BUILD
 	ldr	r9, =gdata
 #else
-	sub	sp, #GD_SIZE
+	sub	sp, sp, #GD_SIZE
 	bic	sp, sp, #7
 	mov	r9, sp
 #endif
arch/arm/lib/crt0.S +1 -1
index ac54b93..dfc2de9 100644
@@ -67,7 +67,7 @@ ENTRY(_main)
 	ldr	sp, =(CONFIG_SYS_INIT_SP_ADDR)
 #endif
 	bic	sp, sp, #7	/* 8-byte alignment for ABI compliance */
-	sub	sp, #GD_SIZE	/* allocate one GD above SP */
+	sub	sp, sp, #GD_SIZE	/* allocate one GD above SP */
 	bic	sp, sp, #7	/* 8-byte alignment for ABI compliance */
 	mov	r9, sp		/* GD is above SP */
 	mov	r0, #0
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 1/1 arm: use canonical sub mnemonic

Dear Albert Aribaud,

Quoted 8 lines · Andreas Bie?mann

Building some arm boards with older binutils may produce errors like this:

---8<---
crt0.S: Assembler messages:
crt0.S:70: Error: register expected, not '#(184)' -- `sub sp,#(184)' --->8---

Use canonical version of the subtract mnemonic to avoid those issues.

any comment?

Best regards

Andreas Bie?mann

#2 lore raw

PATCH 1/1 arm: use canonical sub mnemonic

Hi Andreas,

Quoted 5 lines · Andreas Bie?mann

Dear Albert Aribaud,

Quoted 2 lines · Andreas Bie?mann

Building some arm boards with older binutils may produce errors like this:

Quoted 8 lines
Quoted 6 lines

---8<---
crt0.S: Assembler messages:
crt0.S:70: Error: register expected, not '#(184)' -- `sub sp,#(184)' --->8---

Use canonical version of the subtract mnemonic to avoid those issues.

any comment?

None; I just haven't arrived to applying it yet. Will happen during the day.

Quoted 3 lines

Best regards

Andreas Bie?mann

Amicalement,

Signature · 1 line
Albert.
#3 lore raw

PATCH 1/1 arm: use canonical sub mnemonic

In reply to Andreas Bießmann

Hi Andreas,

Quoted 35 lines · Andreas Bie?mann

Building some arm boards with older binutils may produce errors like this:

---8<---
crt0.S: Assembler messages:
crt0.S:70: Error: register expected, not '#(184)' -- `sub sp,#(184)' --->8---

Use canonical version of the subtract mnemonic to avoid those issues.

---

 arch/arm/cpu/armv7/lowlevel_init.S |    2 +-
 arch/arm/lib/crt0.S                |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +1 -1
index 69e3053..f1aea05 100644
@@ -24,7 +24,7 @@ ENTRY(lowlevel_init)
 #ifdef CONFIG_SPL_BUILD
 	ldr	r9, =gdata
 #else
-	sub	sp, #GD_SIZE
+	sub	sp, sp, #GD_SIZE
 	bic	sp, sp, #7
 	mov	r9, sp
 #endif
arch/arm/lib/crt0.S +0 -0
index ac54b93..dfc2de9 100644

arch/arm/lib/crt0.S ENTRY(_main) · line 73

Quoted 8 lines
arch/arm/lib/crt0.S +1 -1
@@ -67,7 +67,7 @@ ENTRY(_main)
 	ldr	sp, =(CONFIG_SYS_INIT_SP_ADDR)
 #endif
 	bic	sp, sp, #7	/* 8-byte alignment for ABI compliance */
-	sub	sp, #GD_SIZE	/* allocate one GD above SP */
+	sub	sp, sp, #GD_SIZE	/* allocate one GD above SP */
 	bic	sp, sp, #7	/* 8-byte alignment for ABI compliance */
 	mov	r9, sp		/* GD is above SP */
 	mov	r0, #0

Applied to u-boot-arm/master, thanks!

Amicalement,

Signature · 1 line
Albert.