mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-21 02:28:34 -04:00
This reverts commit adbfca5420
.
This commit is contained in:
parent
ebda49376e
commit
10a0b1e54b
7 changed files with 33 additions and 219 deletions
|
@ -301,41 +301,21 @@
|
|||
* *bitwise inverse* of the old mem if the mem wasn't written. This doesn't seem to happen on the
|
||||
* ESP32 (portMUX assertions would fail).
|
||||
*/
|
||||
static inline void uxPortCompareSet( volatile uint32_t * addr,
|
||||
uint32_t compare,
|
||||
uint32_t * set )
|
||||
{
|
||||
#if ( XCHAL_HAVE_S32C1I > 0 )
|
||||
static inline void uxPortCompareSet( volatile uint32_t * addr,
|
||||
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 )
|
||||
);
|
||||
#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,
|
||||
uint32_t compare,
|
||||
uint32_t * set );
|
||||
void uxPortCompareSetExtram( volatile uint32_t * addr,
|
||||
uint32_t compare,
|
||||
uint32_t * set );
|
||||
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
|
@ -427,6 +407,13 @@
|
|||
#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