zephyr/kernel
Andy Ross c0183fdedd kernel/work_q: Fix locking across multiple queues
There was a detected user error in the code where racing insertions of
k_delayed_work items into different queues would be detected and
flagged as an error (honestly I don't see much value there -- Zephyr
doesn't as a general rule protect against errors like this, and
work_q's are inherently kernel things that don't require
userspace-style checking).

This got broken with spinlockification, where each work_q object got
its own lock, so the single lock wouldn't protect against the other
insert function any more.  As it happens, that was needless.  The core
synchronization on a work_q is in the internal k_queue object anyway
-- the lock in this file was only ever used for (very fast,
noncontending) delayed work insertion.  So go back to a global lock to
preserve the original behavior.

Fixes #14104

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2019-03-12 18:37:41 +01:00
..
include all: Update reserved function names 2019-03-11 13:48:42 -04:00
CMakeLists.txt cmake: Use variables for target names 2019-01-19 07:21:55 -05:00
Kconfig kernel: Make heap smallest object size configurable 2019-03-12 11:56:31 +01:00
Kconfig.power_mgmt power: rename CPU_LPS_n power states 2019-02-26 02:30:13 +01:00
atomic_c.c kernel/atomic_c: Spinlockify 2019-02-08 14:49:39 -05:00
compiler_stack_protect.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
device.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
errno.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
idle.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
init.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
int_latency_bench.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
mailbox.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
mem_domain.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
mem_slab.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
mempool.c kernel: Make heap smallest object size configurable 2019-03-12 11:56:31 +01:00
msg_q.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
mutex.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
pipes.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
poll.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
queue.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
sched.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
sem.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
smp.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
stack.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
system_work_q.c kernel: system_work_q: Set dedicated "sysworkq" name. 2018-10-19 07:58:45 -04:00
thread.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
thread_abort.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
timeout.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
timer.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
userspace.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
userspace_handler.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
version.c doc: add kernel version API to doxygen 2018-12-08 17:24:53 -05:00
work_q.c kernel/work_q: Fix locking across multiple queues 2019-03-12 18:37:41 +01:00