nuttx/sched/task
Masayuki Ishikawa 4cc38caba9 sched: Fix nx_waitid(), nx_waitpid(), nxtask_exithook() for SMP
Summary:
- I noticed waitpid_test stops with lc823450-xgevk:rndis
- The condition was CONFIG_DEBUG_ASSERTION=y
- Actually, the child task sent SIGCHILD but the parent couldn't catch the signal
- Then, I found that nx_waitid(), nx_waitpid() use sched_lock()
- However, a parent task and a child task are running on different CPUs
- So, sched_lock() is not enough and need to use a critical section
- Also, signal handling in nxtask_exithook() must be done in a critical section

Impact:
- SMP only

Testing:
- Tested with ostest with the following configurations
- lc823450-xgevk:rndis (CONFIG_DEBUG_ASSERTION=y and n)
- spresense:smp
- spresense:wifi_smp (NCPUS=2 and 4)
- sabre-6quad:smp (QEMU)
- esp32-core:smp (QEMU)
- maix-bit:smp (QEMU)
- sim:smp

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-11-14 16:31:49 -08:00
..
exit.c
Make.defs
spawn.h
task_activate.c
task_atexit.c
task_cancelpt.c
task_create.c
task_delete.c
task_execv.c
task_exit.c sched: task: Fix nxtask_exit() for SMP 2020-11-09 10:59:20 +01:00
task_exithook.c sched: Fix nx_waitid(), nx_waitpid(), nxtask_exithook() for SMP 2020-11-14 16:31:49 -08:00
task_getgroup.c
task_getpid.c
task_init.c Revert "sched: Call up_[use|create]_stack after nxtask_setup_scheduler" 2020-10-22 18:31:31 +09:00
task_onexit.c
task_posixspawn.c
task_prctl.c
task_recover.c
task_reparent.c
task_restart.c
task_setcancelstate.c
task_setcanceltype.c
task_setup.c
task_spawn.c
task_spawnparms.c sched: use nx_close instead of close 2020-10-28 09:11:50 -07:00
task_start.c
task_starthook.c
task_terminate.c sched/task: do not migrate the task state to INVALID 2020-10-28 11:15:22 -07:00
task_testcancel.c
task_vfork.c
task.h