\r
/* Only continue if the CPU is not in User mode. The CPU must be in a\r
Privileged mode for the scheduler to start. */\r
- __asm volatile ( "MRS %0, APSR" : "=r" ( ulAPSR ) );\r
+ __asm volatile ( "MRS %0, APSR" : "=r" ( ulAPSR ) :: "memory" );\r
ulAPSR &= portAPSR_MODE_BITS_MASK;\r
configASSERT( ulAPSR != portAPSR_USER_MODE );\r
\r
ulPortTaskHasFPUContext = pdTRUE;\r
\r
/* Initialise the floating point status register. */\r
- __asm volatile ( "FMXR FPSCR, %0" :: "r" (ulInitialFPSCR) );\r
+ __asm volatile ( "FMXR FPSCR, %0" :: "r" (ulInitialFPSCR) : "memory" );\r
}\r
/*-----------------------------------------------------------*/\r
\r
\r
#define portYIELD_FROM_ISR( x ) portEND_SWITCHING_ISR( x )\r
#define portYIELD() __asm volatile ( "SWI 0 \n" \\r
- "ISB " );\r
+ "ISB " ::: "memory" );\r
\r
\r
/*-----------------------------------------------------------\r
globally enable and disable interrupts. */\r
#define portENTER_CRITICAL() vPortEnterCritical();\r
#define portEXIT_CRITICAL() vPortExitCritical();\r
-#define portENABLE_INTERRUPTS() __asm volatile ( "CPSIE i \n" );\r
+#define portENABLE_INTERRUPTS() __asm volatile ( "CPSIE i \n" ::: "memory" );\r
#define portDISABLE_INTERRUPTS() __asm volatile ( "CPSID i \n" \\r
"DSB \n" \\r
- "ISB " );\r
+ "ISB " ::: "memory" );\r
\r
__attribute__( ( always_inline ) ) static __inline uint32_t portINLINE_SET_INTERRUPT_MASK_FROM_ISR( void )\r
{\r
volatile uint32_t ulCPSR;\r
\r
- __asm volatile ( "MRS %0, CPSR" : "=r" (ulCPSR) );\r
+ __asm volatile ( "MRS %0, CPSR" : "=r" (ulCPSR) :: "memory" );\r
ulCPSR &= portINTERRUPT_ENABLE_BIT;\r
portDISABLE_INTERRUPTS();\r
return ulCPSR;\r