mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-08-22 08:15:25 +00:00
k_queue_append and k_queue_alloc_append are in a race condition. Scenario: Using either of the above mentioned functions from a preemptive context, can lead to the element being appended to the queue to be lost. The element loss happens when the k_queue_append is interrupted at a critical point, when the list only contains one element and k_queue_get is called, before the k_queue_append is allowed to complete. Fix: Move sys_sflist_peek_tail inside queue_insert(). Add additional bool paramenter to queue_insert(), to indicate append/prepend operation. Fixes #29257 Signed-off-by: iva kik <megatheriumiva@gmail.com> |
||
---|---|---|
.. | ||
include | ||
atomic_c.c | ||
cache_handlers.c | ||
CMakeLists.txt | ||
compiler_stack_protect.c | ||
device.c | ||
errno.c | ||
fatal.c | ||
futex.c | ||
idle.c | ||
init.c | ||
Kconfig | ||
kheap.c | ||
mailbox.c | ||
mem_domain.c | ||
mem_slab.c | ||
mempool_sys.c | ||
mempool.c | ||
mmu.c | ||
msg_q.c | ||
mutex.c | ||
pipes.c | ||
poll.c | ||
queue.c | ||
sched.c | ||
sem.c | ||
smp.c | ||
stack.c | ||
system_work_q.c | ||
thread_abort.c | ||
thread.c | ||
timeout.c | ||
timer.c | ||
userspace_handler.c | ||
userspace.c | ||
version.c | ||
work_q.c |