zephyr/kernel
Andy Ross 4521e0c111 kernel/sched: Mark sleeping threads suspended
On SMP, there was a bug where the logic that re-adds _current to the
run queue at swap time would accidentally reschedule threads that had
just gone to sleep, because the is_thread_prevented_from_running()
predicate only tests for threads that are "suspended" or "pending" and
not sleeping.

Overload _THREAD_SUSPENDED to indicate "sleeping" also.  Simple fix
for an immediate bug, though long term we really want to unify all the
blocked conditions to prevent this kind of state bug.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2019-03-23 19:28:15 -04:00
..
include kernel/sched: Rework prio validity assertion 2019-03-23 09:53:55 -05:00
atomic_c.c kernel: fix atomic ops in user mode on some arches 2019-03-18 09:18:00 -04:00
CMakeLists.txt cmake: Use variables for target names 2019-01-19 07:21:55 -05:00
compiler_stack_protect.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
device.c device: Extend device_set_power_state API to support async requests 2019-03-14 14:26:15 +01: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
Kconfig kernel/sched: arch/x86_64: Support synchronous k_thread_abort() in SMP 2019-03-13 19:15:20 +01:00
Kconfig.power_mgmt power: rename CPU_LPS_n power states 2019-02-26 02:30:13 +01: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 kernel/sched: Mark sleeping threads suspended 2019-03-23 19:28:15 -04:00
sem.c all: Update reserved function names 2019-03-11 13:48:42 -04:00
smp.c kernel/sched: arch/x86_64: Support synchronous k_thread_abort() in SMP 2019-03-13 19:15:20 +01: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 kernel: amend comment in k_thread_create handler 2019-03-20 13:59:26 -07: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