/* The interrupt management utilities can only be called from ARM mode. When THUMB_INTERWORK is defined the utilities are defined as functions here to ensure a switch to ARM mode. When THUMB_INTERWORK is not defined then the utilities are defined as macros in portmacro.h - as per other ports.  */
void vPortEnterCritical(void)
/* The interrupt management utilities can only be called from ARM mode. When THUMB_INTERWORK is defined the utilities are defined as functions here to ensure a switch to ARM mode. When THUMB_INTERWORK is not defined then the utilities are defined as macros in portmacro.h - as per other ports.  */
void vPortEnterCritical(void)
{
	asm volatile ( 
		"STMDB	SP!, {R0}			\n\t"
		"MRS	R0, CPSR			\n\t"
		"ORR	R0, R0, #0xC0		\n\t"
		"MSR	CPSR, R0			\n\t"
		"LDMIA	SP!, {R0}" );
	ulCriticalNesting++;
}