Add barrier instructions to IAR CM3 ports.

This commit is contained in:
Richard Barry 2013-04-16 14:56:49 +00:00
parent be7cae575d
commit 895ee2bb3e
7 changed files with 72 additions and 46 deletions

View file

@ -112,16 +112,16 @@ volatile unsigned short usCriticalNesting = portINITIAL_CRITICAL_NESTING;
/*
* Sets up the periodic ISR used for the RTOS tick using the interval timer.
* The application writer can define configSETUP_TIMER_INTERRUPT() (in
* The application writer can define configSETUP_TICK_INTERRUPT() (in
* FreeRTOSConfig.h) such that their own tick interrupt configuration is used
* in place of prvSetupTimerInterrupt().
*/
static void prvSetupTimerInterrupt( void );
#ifndef configSETUP_TIMER_INTERRUPT
#ifndef configSETUP_TICK_INTERRUPT
/* The user has not provided their own tick interrupt configuration so use
the definition in this file (which uses the interval timer). */
#define configSETUP_TIMER_INTERRUPT() prvSetupTimerInterrupt()
#endif /* configSETUP_TIMER_INTERRUPT */
#define configSETUP_TICK_INTERRUPT() prvSetupTimerInterrupt()
#endif /* configSETUP_TICK_INTERRUPT */
/*
* Defined in portasm.s87, this function starts the scheduler by loading the
@ -218,7 +218,7 @@ portBASE_TYPE xPortStartScheduler( void )
{
/* Setup the hardware to generate the tick. Interrupts are disabled when
this function is called. */
configSETUP_TIMER_INTERRUPT();
configSETUP_TICK_INTERRUPT();
/* Restore the context of the first task that is going to run. */
vPortStartFirstTask();
@ -227,7 +227,7 @@ portBASE_TYPE xPortStartScheduler( void )
prvSetupTimerInterrupt() is called here to prevent the compiler outputting
a warning about a statically declared function not being referenced in the
case that the application writer has provided their own tick interrupt
configuration routine (and defined configSETUP_TIMER_INTERRUPT() such that
configuration routine (and defined configSETUP_TICK_INTERRUPT() such that
their own routine will be called in place of prvSetupTimerInterrupt()). */
prvSetupTimerInterrupt();
return pdTRUE;