Skip to content

Commit

Permalink
Merge pull request #1803 from jbruneaux31/patch-1
Browse files Browse the repository at this point in the history
Update osal_freertos.h to fix FreeRTOS wrong task switch
  • Loading branch information
hathach committed Dec 20, 2022
2 parents 159aa59 + a46ad8f commit 97984b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/osal/osal_freertos.h
Expand Up @@ -115,7 +115,7 @@ TU_ATTR_ALWAYS_INLINE static inline bool osal_semaphore_post(osal_semaphore_t se
}
else
{
BaseType_t xHigherPriorityTaskWoken;
BaseType_t xHigherPriorityTaskWoken = pdFALSE;
BaseType_t res = xSemaphoreGiveFromISR(sem_hdl, &xHigherPriorityTaskWoken);

#if CFG_TUSB_MCU == OPT_MCU_ESP32S2 || CFG_TUSB_MCU == OPT_MCU_ESP32S3
Expand Down Expand Up @@ -189,7 +189,7 @@ TU_ATTR_ALWAYS_INLINE static inline bool osal_queue_send(osal_queue_t qhdl, void
}
else
{
BaseType_t xHigherPriorityTaskWoken;
BaseType_t xHigherPriorityTaskWoken = pdFALSE;
BaseType_t res = xQueueSendToBackFromISR(qhdl, data, &xHigherPriorityTaskWoken);

#if CFG_TUSB_MCU == OPT_MCU_ESP32S2 || CFG_TUSB_MCU == OPT_MCU_ESP32S3
Expand Down

0 comments on commit 97984b4

Please sign in to comment.