1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/cpu/esp_common/freertos
Gunar Schorcht 35676ca712 cpu/esp_common: fix of blocking mechanism in FreeRTOS queus
When FreeRTOS semaphores, as required by ESP-IDF, are used together with `gnrc_netif`, RIOT may crash if `STATUS_RECEIVE_BLOCKED` is used as a blocking mechanism in the FreeRTOS adaptation layer. The reason for this is that `gnrc_netif` uses thread flags since PR #16748. If the `gnrc_netif` thread is blocked because of a FreeRTOS semaphore, and is thus in `STATUS_RECEIVE_BLOCKED` state, the `_msg_send` function will cause a crash because it then assumes that `target->wait_data` contains a pointer to a message of type `msg_t`, but by using thread flags it contains the flag mask. This situation can happen if the ESP hardware is used while another thread is sending something timer controlled to the `gnrc_netif` thread.

To solve this problem `STATUS_MUTEX_LOCKED` is used instead of `STATUS_RECEIVE_BLOCKED` and `STATUS_SEND_BLOCKED`
2022-08-24 09:05:25 +02:00
..
event_groups.c cpu/*: realign ENABLE_DEBUG 2020-10-23 00:46:26 +02:00
Kconfig cpu/esp_common: model Kconfig 2021-12-10 18:54:07 +01:00
Makefile cpu/esp_common: add module esp_freertos_common 2020-02-21 09:09:34 +01:00
portable.c cpu/esp_common/freertos: missing functions/definitions for ESP-IDF v4.4 2022-06-01 13:21:29 +02:00
queue.c cpu/esp_common: fix of blocking mechanism in FreeRTOS queus 2022-08-24 09:05:25 +02:00
ringbuf.c cpu/esp_common/freertos: add required ringbuffer handling 2022-06-20 21:23:47 +02:00
semphr.c cpu/esp_common/freertos: add xSemaphoreGetMutexHolder 2022-06-20 21:23:47 +02:00
task.c cpu/esp*: cleanups mainly to reduce the vera++ warnings 2022-07-20 06:29:43 +02:00
timers.c cpu/esp_common/freertos: allow platform independent compilation 2022-06-20 21:23:47 +02:00