mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-25 17:58:46 +00:00
fix(freertos): Incorrect assert in FreeRTOS port layer when not in ISR context
This commit fixes an issue where in the FreeRTOS port layer would cause the portASSERT_IF_IN_ISR() assert check to fail even when the system is not in an interrupt context.
This commit is contained in:
@@ -166,6 +166,13 @@ void vPortClearInterruptMaskFromISR(UBaseType_t prev_int_level);
|
||||
*/
|
||||
BaseType_t xPortInIsrContext(void);
|
||||
|
||||
/**
|
||||
* @brief Assert if in ISR context
|
||||
*
|
||||
* - Asserts on xPortInIsrContext() internally
|
||||
*/
|
||||
void vPortAssertIfInISR(void);
|
||||
|
||||
/**
|
||||
* @brief Check if in ISR context from High priority ISRs
|
||||
*
|
||||
@@ -478,6 +485,11 @@ void vPortTCBPreDeleteHook( void *pxTCB );
|
||||
#define portSET_INTERRUPT_MASK_FROM_ISR() xPortSetInterruptMaskFromISR()
|
||||
#define portCLEAR_INTERRUPT_MASK_FROM_ISR(prev_level) vPortClearInterruptMaskFromISR(prev_level)
|
||||
|
||||
/**
|
||||
* @brief Assert if in ISR context
|
||||
*/
|
||||
#define portASSERT_IF_IN_ISR() vPortAssertIfInISR()
|
||||
|
||||
/**
|
||||
* @brief Used by FreeRTOS functions to call the correct version of critical section API
|
||||
*/
|
||||
|
Reference in New Issue
Block a user