mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-20 18:18:32 -04:00
parent
4383c8fae3
commit
adbfca5420
7 changed files with 217 additions and 31 deletions
|
@ -305,12 +305,32 @@
|
|||
uint32_t compare,
|
||||
uint32_t * set )
|
||||
{
|
||||
__asm__ __volatile__ (
|
||||
"WSR %2,SCOMPARE1 \n"
|
||||
"S32C1I %0, %1, 0 \n"
|
||||
: "=r" ( *set )
|
||||
: "r" ( addr ), "r" ( compare ), "0" ( *set )
|
||||
);
|
||||
#if ( XCHAL_HAVE_S32C1I > 0 )
|
||||
__asm__ __volatile__ (
|
||||
"WSR %2,SCOMPARE1 \n"
|
||||
"S32C1I %0, %1, 0 \n"
|
||||
: "=r" ( *set )
|
||||
: "r" ( addr ), "r" ( compare ), "0" ( *set )
|
||||
);
|
||||
#else
|
||||
/* No S32C1I, so do this by disabling and re-enabling interrupts (slower) */
|
||||
uint32_t intlevel, old_value;
|
||||
__asm__ __volatile__ ( "rsil %0, " XTSTR( XCHAL_EXCM_LEVEL ) "\n"
|
||||
: "=r" ( intlevel ) );
|
||||
|
||||
old_value = *addr;
|
||||
|
||||
if( old_value == compare )
|
||||
{
|
||||
*addr = *set;
|
||||
}
|
||||
|
||||
__asm__ __volatile__ ( "memw \n"
|
||||
"wsr %0, ps\n"
|
||||
: : "r" ( intlevel ) );
|
||||
|
||||
*set = old_value;
|
||||
#endif /* if ( XCHAL_HAVE_S32C1I > 0 ) */
|
||||
}
|
||||
|
||||
void uxPortCompareSetExtram( volatile uint32_t * addr,
|
||||
|
@ -407,13 +427,6 @@
|
|||
#define xPortGetFreeHeapSize esp_get_free_heap_size
|
||||
#define xPortGetMinimumEverFreeHeapSize esp_get_minimum_free_heap_size
|
||||
|
||||
/*
|
||||
* Send an interrupt to another core in order to make the task running
|
||||
* on it yield for a higher-priority task.
|
||||
*/
|
||||
|
||||
void vPortYieldOtherCore( BaseType_t coreid ) PRIVILEGED_FUNCTION;
|
||||
|
||||
|
||||
/*
|
||||
* Callback to set a watchpoint on the end of the stack. Called every context switch to change the stack
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue