esp-idf/components/freertos/include/freertos
Darian Leung ad39eaaeb0 freertos: Fix event group task list race condition
FreeRTOS synchronization primitives (e.g., queues, eventgroups) use various event lists (i.e., task lists) to track what
tasks are blocked on a current primitive. Usually these event lists are accessed via one of the event lists functions
(such as vTask[PlaceOn|RemoveFrom]UnorderedEventList()), which in turn ensure that the global task list spinlock
(xTaskQueueMutex) is taken when accessing these lists.

However, some functions in event_groups.c manually traverse their event lists. Thus if a tick interrupt occurs on
another core during traversal and that tick interrupt unblocks a task on the event list being traversed, the event list
will be corrupted.

This commit modifies the following event_groups.c functions so that they take the global task list lock before
traversing their event list.

- xEventGroupSetBits()
- vEventGroupDelete()
2022-07-25 03:01:16 +00:00
..
atomic.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
croutine.h freertos: merged freertos 10 kernel files into IDF 2020-10-13 23:52:03 +00:00
deprecated_definitions.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
event_groups.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
FreeRTOS.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
list.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
message_buffer.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
mpu_wrappers.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
portable.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
projdefs.h freertos: Fix loss of precision in pdTICKS_TO_MS 2022-01-06 15:54:01 +08:00
queue.h docs:fix broken links 2022-02-15 14:28:59 +08:00
semphr.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
stack_macros.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
stdint.readme freertos: merged freertos 10 kernel files into IDF 2020-10-13 23:52:03 +00:00
stream_buffer.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00
task.h freertos: Fix event group task list race condition 2022-07-25 03:01:16 +00:00
timers.h Whitespace: Automated whitespace fixes (large commit) 2020-11-11 07:36:35 +00:00