aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2015-11-19 16:13:55 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2015-11-19 16:13:55 +0000
commit4db0944ed00e6a31674c10d71d26d5d80f4d74d7 (patch)
tree92be3d01f9f88eba1e171ffe5d6592a0ad0f0ba6
parentd5e213f8cba8dd6641f4d2d19855ed2f9e4e4218 (diff)
downloadChibiOS-4db0944ed00e6a31674c10d71d26d5d80f4d74d7.tar.gz
ChibiOS-4db0944ed00e6a31674c10d71d26d5d80f4d74d7.tar.bz2
ChibiOS-4db0944ed00e6a31674c10d71d26d5d80f4d74d7.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8510 35acf78f-673a-0410-8e92-d51de3d6d3f4
-rw-r--r--demos/SPC5/RT-SPC560D-EVB-CW/cw/ch/ch.mcpbin47603 -> 45755 bytes
-rw-r--r--os/common/ports/e200/compilers/CW/crt0.s32
-rw-r--r--os/common/ports/e200/compilers/CW/vectors.s8
-rw-r--r--os/common/ports/e200/devices/SPC560Dxx/boot_cw.s55
-rw-r--r--os/rt/ports/e200/compilers/CW/chcoreasm.s4
-rw-r--r--os/rt/ports/e200/compilers/CW/ivor.s14
6 files changed, 70 insertions, 43 deletions
diff --git a/demos/SPC5/RT-SPC560D-EVB-CW/cw/ch/ch.mcp b/demos/SPC5/RT-SPC560D-EVB-CW/cw/ch/ch.mcp
index 687bd78e2..8e5821d29 100644
--- a/demos/SPC5/RT-SPC560D-EVB-CW/cw/ch/ch.mcp
+++ b/demos/SPC5/RT-SPC560D-EVB-CW/cw/ch/ch.mcp
Binary files differ
diff --git a/os/common/ports/e200/compilers/CW/crt0.s b/os/common/ports/e200/compilers/CW/crt0.s
index cb5334df3..a0031d2e1 100644
--- a/os/common/ports/e200/compilers/CW/crt0.s
+++ b/os/common/ports/e200/compilers/CW/crt0.s
@@ -59,7 +59,7 @@
* @brief DATA segment initialization switch.
*/
#if !defined(CRT0_INIT_DATA) || defined(__DOXYGEN__)
-#define CRT0_INIT_DATA TRUE
+#define CRT0_INIT_DATA FALSE
#endif
/**
@@ -73,14 +73,14 @@
* @brief Constructors invocation switch.
*/
#if !defined(CRT0_CALL_CONSTRUCTORS) || defined(__DOXYGEN__)
-#define CRT0_CALL_CONSTRUCTORS TRUE
+#define CRT0_CALL_CONSTRUCTORS FALSE
#endif
/**
* @brief Destructors invocation switch.
*/
#if !defined(CRT0_CALL_DESTRUCTORS) || defined(__DOXYGEN__)
-#define CRT0_CALL_DESTRUCTORS TRUE
+#define CRT0_CALL_DESTRUCTORS FALSE
#endif
/*===========================================================================*/
@@ -88,9 +88,25 @@
/*===========================================================================*/
#if !defined(__DOXYGEN__)
-
- .section .crt0, "ax"
- .align 2
+ .extern __sdata2_start__
+ .extern __sdata_start__
+ .extern __bss_start__
+ .extern __bss_end__
+ .extern __irq_stack_base__
+ .extern __irq_stack_end__
+ .extern __process_stack_end__
+ .extern __process_stack_base__
+ .extern __romdata_start__
+ .extern __data_start__
+ .extern __data_end__
+ .extern __init_array_start
+ .extern __init_array_end
+ .extern __fini_array_start
+ .extern __fini_array_end
+ .extern main
+
+ .section .crt0, 16
+ .align 4
.globl _boot_address
.type _boot_address, @function
_boot_address:
@@ -116,7 +132,7 @@ _boot_address:
/* IRQ Stack initialization. Note, the architecture does not use this
stack, the size is usually zero. An OS can have special SW handling
- and require this. A 4 bytes alignment is assmend and required.*/
+ and require this. A 4 bytes alignment is assumed and required.*/
e_lis r4, __irq_stack_base__@h
e_or2i r4, __irq_stack_base__@l
e_lis r5, __irq_stack_end__@h
@@ -130,7 +146,7 @@ _boot_address:
.irqsend:
/* Process Stack initialization. Note, does not overwrite the already
- written EABI frame. A 4 bytes alignment is assmend and required.*/
+ written EABI frame. A 4 bytes alignment is assumed and required.*/
e_lis r4, __process_stack_base__@h
e_or2i r4, __process_stack_base__@l
e_lis r5, (__process_stack_end__ - 8)@h
diff --git a/os/common/ports/e200/compilers/CW/vectors.s b/os/common/ports/e200/compilers/CW/vectors.s
index aa07c9e82..7d0592f5b 100644
--- a/os/common/ports/e200/compilers/CW/vectors.s
+++ b/os/common/ports/e200/compilers/CW/vectors.s
@@ -38,8 +38,8 @@
handler only. In order to declare an interrupt handler just create
a function withe the same name of a vector, the symbol will
override the weak symbol declared here.*/
- .section .vectors, "ax"
- .align 4
+ .section .vectors, 16
+ .align 16
.globl _vectors
_vectors:
.long vector0, vector1, vector2, vector3
@@ -800,8 +800,8 @@ _vectors:
.long vector1008, vector1009, vector1010, vector1011
#endif
- .text
- .align 2
+/* .section .text, 16*/
+ .align 16
.weak vector0, vector1, vector2, vector3
#if PPC_NUM_VECTORS > 4
diff --git a/os/common/ports/e200/devices/SPC560Dxx/boot_cw.s b/os/common/ports/e200/devices/SPC560Dxx/boot_cw.s
index cd925877e..a5a8a69ec 100644
--- a/os/common/ports/e200/devices/SPC560Dxx/boot_cw.s
+++ b/os/common/ports/e200/devices/SPC560Dxx/boot_cw.s
@@ -29,13 +29,18 @@
#if !defined(__DOXYGEN__)
+ .extern _boot_address
+ .extern __ram_start__
+ .extern __ram_end__
+ .extern __ivpr_base__
+
/* BAM record.*/
- .section .boot, "ax"
+ .section .boot, 16
.long 0x015A0000
.long _reset_address
- .align 2
+ .align 4
.globl _reset_address
.type _reset_address, @function
_reset_address:
@@ -72,7 +77,7 @@ _reset_address:
#endif
#if BOOT_PERFORM_CORE_INIT
- .align 2
+ .align 4
_coreinit:
/*
* RAM clearing, this device requires a write to all RAM location in
@@ -135,7 +140,7 @@ _coreinit:
/*
* Exception vectors initialization.
*/
- .align 2
+ .align 4
_ivinit:
/* MSR initialization.*/
e_lis r3, BOOT_MSR_DEFAULT@h
@@ -149,48 +154,42 @@ _ivinit:
se_blr
- .section .ivors, "ax"
-
+ .section .ivors, 16
.globl IVORS
IVORS:
e_b _IVOR0
- .align 4
+ .align 16
e_b _IVOR1
- .align 4
+ .align 16
e_b _IVOR2
- .align 4
+ .align 16
e_b _IVOR3
- .align 4
+ .align 16
e_b _IVOR4
- .align 4
+ .align 16
e_b _IVOR5
- .align 4
+ .align 16
e_b _IVOR6
- .align 4
+ .align 16
e_b _IVOR7
- .align 4
+ .align 16
e_b _IVOR8
- .align 4
+ .align 16
e_b _IVOR9
- .align 4
+ .align 16
e_b _IVOR10
- .align 4
+ .align 16
e_b _IVOR11
- .align 4
+ .align 16
e_b _IVOR12
- .align 4
+ .align 16
e_b _IVOR13
- .align 4
+ .align 16
e_b _IVOR14
- .align 4
+ .align 16
e_b _IVOR15
- .section .handlers, "ax"
-
- /*
- * Default IVOR handlers.
- */
- .align 2
+ .section .handlers, 16
.weak _IVOR0, _IVOR1, _IVOR2, _IVOR3, _IVOR4, _IVOR5
.weak _IVOR6, _IVOR7, _IVOR8, _IVOR9, _IVOR10, _IVOR11
.weak _IVOR12, _IVOR13, _IVOR14, _IVOR15
@@ -199,11 +198,13 @@ _IVOR0:
_IVOR1:
_IVOR2:
_IVOR3:
+_IVOR4:
_IVOR5:
_IVOR6:
_IVOR7:
_IVOR8:
_IVOR9:
+_IVOR10:
_IVOR11:
_IVOR12:
_IVOR13:
diff --git a/os/rt/ports/e200/compilers/CW/chcoreasm.s b/os/rt/ports/e200/compilers/CW/chcoreasm.s
index 69ab222fa..b33fb1ce2 100644
--- a/os/rt/ports/e200/compilers/CW/chcoreasm.s
+++ b/os/rt/ports/e200/compilers/CW/chcoreasm.s
@@ -50,8 +50,10 @@
#if !defined(__DOXYGEN__)
+ .extern chThdExit
+
#if PPC_USE_VLE == TRUE
- .section .text_vle, "ax"
+ .section .text_vle, 16
.align 2
.globl _port_switch
diff --git a/os/rt/ports/e200/compilers/CW/ivor.s b/os/rt/ports/e200/compilers/CW/ivor.s
index f08075a0c..ce1f79cc1 100644
--- a/os/rt/ports/e200/compilers/CW/ivor.s
+++ b/os/rt/ports/e200/compilers/CW/ivor.s
@@ -50,7 +50,15 @@
#if !defined(__DOXYGEN__)
- .section .handlers, "ax"
+ .extern _stats_start_measure_crit_thd
+ .extern _stats_stop_measure_crit_thd
+ .extern _dbg_check_lock
+ .extern _dbg_check_unlock
+ .extern chSchIsPreemptionRequired
+ .extern chSchDoReschedule
+ .extern chSysTimerHandlerI
+
+ .section .handlers, 16
#if PPC_USE_VLE == TRUE
@@ -58,7 +66,7 @@
/*
* _IVOR10 handler (Book-E decrementer).
*/
- .align 4
+ .align 16
.globl _IVOR10
.type _IVOR10, @function
_IVOR10:
@@ -108,7 +116,7 @@ _IVOR10:
/*
* _IVOR4 handler (Book-E external interrupt).
*/
- .align 4
+ .align 16
.globl _IVOR4
.type _IVOR4, @function
_IVOR4: