[v1,1/4] Alignment libgloss/arm and newlib/libc/sys/arm: reflect commit 9b11672

Message ID 20190801101334.6213-1-alfedotov@gmail.com
State New
Headers show
Series
  • [v1,1/4] Alignment libgloss/arm and newlib/libc/sys/arm: reflect commit 9b11672
Related show

Commit Message

Alexander Fedotov Aug. 1, 2019, 10:13 a.m.
---
 newlib/libc/sys/arm/crt0.S | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

-- 
2.17.1

Comments

Corinna Vinschen Aug. 1, 2019, 10:55 a.m. | #1
Alexander,

can you please create better commit messages?  A short, concise subject
line with not more than ~70 chars, plus a commit message body describing
your change in a few more words.  What do you mean by "reflecting" a
commit SHA-1?  That's not at all helpful for the future reader.


Thanks,
Corinna

-- 
Corinna Vinschen
Cygwin Maintainer
Red Hat

Patch

diff --git a/newlib/libc/sys/arm/crt0.S b/newlib/libc/sys/arm/crt0.S
index 9c262428d..40bbc3d69 100644
--- a/newlib/libc/sys/arm/crt0.S
+++ b/newlib/libc/sys/arm/crt0.S
@@ -393,13 +393,14 @@  __change_mode:
 	movs	r1, r0
 #else
 	movs	r0, #AngelSWI_Reason_GetCmdLine
-	adr	r1, .LC30	/* Space for command line.  */
+	ldr	r1, .LC30	/* Space for command line.  */
 #ifdef THUMB_VXM
 	bkpt	AngelSWI
 #else
  	AngelSWIAsm	AngelSWI
 #endif
 	ldr	r1, .LC30
+	ldr	r1, [r1]
 #endif
 	/*  Parse string at r1.  */
 	movs	r0, #0		/* Count of arguments so far.  */
@@ -586,8 +587,7 @@  change_back:
 #endif
 #ifdef ARM_RDI_MONITOR
 .LC30:
-	.word	CommandLine
-	.word	255
+	.word	AngelSWIArgs
 .LC31:
 	.word	__end__
 
@@ -600,6 +600,9 @@  HeapLimit:	.word	0
 __stack_base__:	.word	0
 StackLimit:	.word	0
 CommandLine:	.space	256,0	/*  Maximum length of 255 chars handled.  */
+AngelSWIArgs:
+	.word	CommandLine
+	.word	255
 #endif
 	
 #ifdef __pe__