Fix the regression by commit:
commit 8b67944c75
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date: Thu Oct 14 11:03:07 2021 +0800
sched: Remove pidhash_s and move ticks to tcb_s
simplify the code logic and reduce memory a little bit
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
when enable SYSTEM_TIME64, tick may exceed the int32 range
example:
pthread_cond_clockwait
---->clock_abstime2ticks
---->wd_start
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
the logical may choose the head of g_readytorun(the greatest priority)
task as the next while ignoring the cpu affinity of it.
Signed-off-by: chenhonglin <chenhonglin@xiaomi.com>
In "nxsched_nexttcb": the task may not running on this_cpu,
and rtrtcb->affinity(the affinity of the task in g_readytorun)
may not include the current cpu which should be the tcb->cpu.
Signed-off-by: chenhonglin <chenhonglin@xiaomi.com>
If statement in line 103 could acces wdactivelist.head->lag when head was
NULL which could result in hard fault. The statement was also redundant
as the same condition is checked in the while loop below. This change
remove the if statement to prevent hard fault to occur.
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
nxspawn_open() is expected to return "OK" when it success, but
it doesn't return it in case of executing dup2.
Because of this, the "Command as parameter" couldn't work with
Builtin Apps.
include/nuttx/wqueue.h:
libs/libc/wqueue/work_cancel.c:
libs/libc/wqueue/work_queue.c:
sched/wqueue/kwork_cancel.c:
sched/wqueue/kwork_queue.c:
* Fix spelling, grammar, and typos.
* Improve wording in a few areas.
* These changes affect comments only. No functional changes.
and change the default value of IDLETHREAD_STACKSIZE to 65536
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia54efbbca4b69706150bc4178844b316688a104e
Note: all attributes is guarded by PSEUDOFS_ATTRIBUTES to save the space
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I664d60382e356068fd920f08aca5b4a49d8d92a9
MIRTOS-109
Return error when tv_nsec <0 or >=1000 million.
Change-Id: Iddbbcda163cb402551f619efb7486f6798859d57
Signed-off-by: Peter Bee <bijunda1@xiaomi.com>
Fail case:
exit -> nxtask_terminate -> nxtask_exithook -> nxsched_release_tcb
group_leave || nxsched_releasepid & group_leave
/\
/ \
switch out & waitpid()
Thread A group_leave in nxtask_exithook, switch out,
Thread B do waitpid(thread A) then meet traget thread A group is NULL, error.
Change-Id: Ia181d7a13aa645ec1c3141a45839fbf79db35b17
Signed-off-by: ligd <liguiding1@xiaomi.com>
Because idle task will call mm_malloc to create some task
and will take sem of mm. But if smp enable, the sem of mm may be
taken by other cpu, so idle may be block because take this sem and crash.
Change-Id: I22f0233ef6c59a1b81607d4389e68f8646c89395
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
Documentation/reference/os/wqueue.rst:
* CONFIG_SIG_SIGWORK: Fix sentence that was cut off in the
middle.
include/signal.h:
* SIGWORK: Fix grammar in comment.
sched/Kconfig:
* config SIG_SIGWORK: Fix ---help--- text to indicate that
this user-configured signal number may be used by various
internal worker threads.