fix relocation of R2

This commit is contained in:
NIIBE Yutaka
2013-12-11 22:00:15 +09:00
parent a39c8ee878
commit 2ff20397ca
2 changed files with 5 additions and 1 deletions

View File

@@ -1,3 +1,7 @@
2013-12-11 Niibe Yutaka <gniibe@fsij.org>
* regnual/sys.c (entry): Fix relocation calculation.
2013-11-27 Niibe Yutaka <gniibe@fsij.org> 2013-11-27 Niibe Yutaka <gniibe@fsij.org>
* src/stm32f103.h (AFIO_MAPR_SWJ_CFG_DISABLE): New. * src/stm32f103.h (AFIO_MAPR_SWJ_CFG_DISABLE): New.

View File

@@ -42,7 +42,7 @@ void entry (void)
"add r1, r0\n\t" /* relocate bss_start */ "add r1, r0\n\t" /* relocate bss_start */
"ldr r4, .L00+8\n\t" "ldr r4, .L00+8\n\t"
"ldr r2, [r3, r4]\n" "ldr r2, [r3, r4]\n"
"add r1, r0\n\t" /* relocate bss_end */ "add r2, r0\n\t" /* relocate bss_end */
/* Clear BSS. */ /* Clear BSS. */
"mov r0, #0\n\t" "mov r0, #0\n\t"
"0:\n\t" "0:\n\t"