aboutsummaryrefslogtreecommitdiffstats
path: root/os/ports/GCC
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-12-21 10:30:39 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-12-21 10:30:39 +0000
commitf2386f6a22c55842203278c5b1f9691c5ac5f8fd (patch)
treeb7f318640fa8ff688925eab4fe544d41f3dd019a /os/ports/GCC
parent25d2722b09c5ed808fbb5b09bafc94f253da2479 (diff)
downloadChibiOS-f2386f6a22c55842203278c5b1f9691c5ac5f8fd.tar.gz
ChibiOS-f2386f6a22c55842203278c5b1f9691c5ac5f8fd.tar.bz2
ChibiOS-f2386f6a22c55842203278c5b1f9691c5ac5f8fd.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2515 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/ports/GCC')
-rw-r--r--os/ports/GCC/ARM/crt0.s14
-rw-r--r--os/ports/GCC/ARM/port.dox2
-rw-r--r--os/ports/GCC/ARMCMx/crt0_v6m.s10
-rw-r--r--os/ports/GCC/ARMCMx/crt0_v7m.s10
-rw-r--r--os/ports/GCC/PPC/crt0.s10
-rw-r--r--os/ports/GCC/PPC/port.dox2
6 files changed, 19 insertions, 29 deletions
diff --git a/os/ports/GCC/ARM/crt0.s b/os/ports/GCC/ARM/crt0.s
index 33cbb5600..b3a6aa392 100644
--- a/os/ports/GCC/ARM/crt0.s
+++ b/os/ports/GCC/ARM/crt0.s
@@ -125,25 +125,21 @@ bssloop:
add r0, pc, #1
bx r0
.code 16
- mov r0, #0
- mov r1, r0
bl main
- ldr r1, =MainExitHandler
+ ldr r1, =_main_exit_handler
bx r1
.code 32
#else
- mov r0, #0
- mov r1, r0
bl main
- b MainExitHandler
+ b _main_exit_handler
#endif
/*
* Default main function exit handler.
*/
- .weak MainExitHandler
- .global MainExitHandler
-MainExitHandler:
+ .weak _main_exit_handler
+ .global _main_exit_handler
+_main_exit_handler:
.loop: b .loop
/*
diff --git a/os/ports/GCC/ARM/port.dox b/os/ports/GCC/ARM/port.dox
index 1e1fb4b64..2fe0f19c2 100644
--- a/os/ports/GCC/ARM/port.dox
+++ b/os/ports/GCC/ARM/port.dox
@@ -195,7 +195,7 @@
* -# The @p main() function is invoked with the parameters @p argc and @p argv
* set to zero.
* -# Should the @p main() function return a branch is performed to the weak
- * symbol MainExitHandler. The default code is an endless empty loop.
+ * symbol _main_exit_handler. The default code is an endless empty loop.
* .
* @section ARM_STARTUP_2 Expected linker symbols
* The startup code starts at the symbol @p ResetHandler and expects the
diff --git a/os/ports/GCC/ARMCMx/crt0_v6m.s b/os/ports/GCC/ARMCMx/crt0_v6m.s
index 82dc066fb..baaf6f32d 100644
--- a/os/ports/GCC/ARMCMx/crt0_v6m.s
+++ b/os/ports/GCC/ARMCMx/crt0_v6m.s
@@ -102,19 +102,17 @@ endbloop:
/*
* Main program invocation.
*/
- movs r0, #0
- mov r1, r0
bl main
- b MainExitHandler
+ b _main_exit_handler
/*
* Default main exit code, just a loop.
* It is a weak symbol, the application code can redefine the behavior.
*/
.thumb_func
- .global MainExitHandler
- .weak MainExitHandler
-MainExitHandler:
+ .global _main_exit_handler
+ .weak _main_exit_handler
+_main_exit_handler:
.loop: b .loop
/*
diff --git a/os/ports/GCC/ARMCMx/crt0_v7m.s b/os/ports/GCC/ARMCMx/crt0_v7m.s
index 1c76975c6..4e4a40631 100644
--- a/os/ports/GCC/ARMCMx/crt0_v7m.s
+++ b/os/ports/GCC/ARMCMx/crt0_v7m.s
@@ -97,19 +97,17 @@ bloop:
/*
* Main program invocation.
*/
- movs r0, #0
- mov r1, r0
bl main
- b MainExitHandler
+ b _main_exit_handler
/*
* Default main exit code, just a loop.
* It is a weak symbol, the application code can redefine the behavior.
*/
.thumb_func
- .global MainExitHandler
- .weak MainExitHandler
-MainExitHandler:
+ .global _main_exit_handler
+ .weak _main_exit_handler
+_main_exit_handler:
.loop: b .loop
/*
diff --git a/os/ports/GCC/PPC/crt0.s b/os/ports/GCC/PPC/crt0.s
index c40f5efb2..0a2697be8 100644
--- a/os/ports/GCC/PPC/crt0.s
+++ b/os/ports/GCC/PPC/crt0.s
@@ -89,17 +89,15 @@ _boot_address:
/*
* Main program invocation.
*/
- li %r3, 0
- li %r4, 0
bl main
- b main_exit
+ b _main_exit_handler
/*
* Default main exit code, infinite loop.
*/
- .weak main_exit
- .globl main_exit
-main_exit:
+ .weak _main_exit_handler
+ .globl _main_exit_handler
+_main_exit_handler:
forever:
b forever
diff --git a/os/ports/GCC/PPC/port.dox b/os/ports/GCC/PPC/port.dox
index 6c3bc55f2..70ba4784a 100644
--- a/os/ports/GCC/PPC/port.dox
+++ b/os/ports/GCC/PPC/port.dox
@@ -112,7 +112,7 @@
* -# The @p main() function is invoked with the parameters @p argc and @p argv
* set to zero.
* -# Should the @p main() function return a branch is performed to the weak
- * symbol @p main_exit. The default code is an endless empty loop.
+ * symbol @p _main_exit_handler. The default code is an endless empty loop.
* .
* @section PPC_STARTUP_2 Expected linker symbols
* The startup code starts at the symbol @p _boot_address and expects the