Revert "fix(freertos): use xSemaphoreTakeRecursive (#6803)"

It causes performance issues in some cases
See https://github.com/lvgl/lvgl/pull/6981#issuecomment-2417037919

This reverts commit 53c846f4ac.
This commit is contained in:
Gabor Kiss-Vamosi
2024-10-23 21:21:24 +02:00
parent ac0cdcb0d9
commit 7d5cb8385e

View File

@@ -129,7 +129,7 @@ lv_result_t lv_mutex_lock(lv_mutex_t * pxMutex)
/* If mutex in uninitialized, perform initialization. */
prvCheckMutexInit(pxMutex);
BaseType_t xMutexTakeStatus = xSemaphoreTakeRecursive(pxMutex->xMutex, portMAX_DELAY);
BaseType_t xMutexTakeStatus = xSemaphoreTake(pxMutex->xMutex, portMAX_DELAY);
if(xMutexTakeStatus != pdTRUE) {
LV_LOG_ERROR("xSemaphoreTake failed!");
return LV_RESULT_INVALID;
@@ -165,7 +165,7 @@ lv_result_t lv_mutex_unlock(lv_mutex_t * pxMutex)
/* If mutex in uninitialized, perform initialization. */
prvCheckMutexInit(pxMutex);
BaseType_t xMutexGiveStatus = xSemaphoreGiveRecursive(pxMutex->xMutex);
BaseType_t xMutexGiveStatus = xSemaphoreGive(pxMutex->xMutex);
if(xMutexGiveStatus != pdTRUE) {
LV_LOG_ERROR("xSemaphoreGive failed!");
return LV_RESULT_INVALID;