From: richardbarry Date: Thu, 13 Jan 2011 10:36:42 +0000 (+0000) Subject: Add the .align, .asmfunc and .endasmfunc directives to the CCS MSP430X port layer. X-Git-Tag: V6.1.1~11 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=4ac24f561d0eeac46b4fe734c64b5569dd52bccf;p=freertos Add the .align, .asmfunc and .endasmfunc directives to the CCS MSP430X port layer. git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@1246 1d2547de-c912-0410-9cb9-b8ca96c0e9e2 --- diff --git a/Source/portable/CCS4/MSP430X/portext.asm b/Source/portable/CCS4/MSP430X/portext.asm index 1e09101f7..5bbb4f19f 100644 --- a/Source/portable/CCS4/MSP430X/portext.asm +++ b/Source/portable/CCS4/MSP430X/portext.asm @@ -107,8 +107,9 @@ portRESTORE_CONTEXT .macro ;*/ .text + .align 2 -vPortPreemptiveTickISR: +vPortPreemptiveTickISR: .asmfunc ; The sr is not saved in portSAVE_CONTEXT() because vPortYield() needs ;to save it manually before it gets modified (interrupts get disabled). @@ -119,9 +120,12 @@ vPortPreemptiveTickISR: call_x #vTaskSwitchContext portRESTORE_CONTEXT + .endasmfunc ;----------------------------------------------------------- -vPortCooperativeTickISR: + .align 2 + +vPortCooperativeTickISR: .asmfunc ; The sr is not saved in portSAVE_CONTEXT() because vPortYield() needs ;to save it manually before it gets modified (interrupts get disabled). @@ -131,12 +135,17 @@ vPortCooperativeTickISR: call_x #vTaskIncrementTick portRESTORE_CONTEXT + + .endasmfunc ;----------------------------------------------------------- -;* -;* Manual context switch called by the portYIELD() macro. -;*/ -vPortYield: +; +; Manual context switch called by the portYIELD() macro. +; + + .align 2 + +vPortYield: .asmfunc ; The sr needs saving before it is modified. push.w sr @@ -153,14 +162,18 @@ vPortYield: ; Restore the context of the new task. portRESTORE_CONTEXT + .endasmfunc ;----------------------------------------------------------- -;* -;* Start off the scheduler by initialising the RTOS tick timer, then restoring -;* the context of the first task. -;* -xPortStartScheduler: +; +; Start off the scheduler by initialising the RTOS tick timer, then restoring +; the context of the first task. +; + + .align 2 + +xPortStartScheduler: .asmfunc ; Setup the hardware to generate the tick. Interrupts are disabled ; when this function is called. @@ -168,6 +181,7 @@ xPortStartScheduler: ; Restore the context of the first task that is going to run. portRESTORE_CONTEXT + .endasmfunc ;----------------------------------------------------------- .end