mirror of
https://github.com/apache/nuttx.git
synced 2026-05-30 21:36:28 +08:00
arch: _exit should't call nxsched_resume_scheduler twice in SMP mode
utilize the call inside nxtask_exit instead, also move nxsched_suspend_scheduler to nxtask_exit for symmetry Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com> Change-Id: I219fc15faf0026e452b0db3906aa40b40ac677f3
This commit is contained in:
committed by
Abdelatif Guettouche
parent
c45289eb89
commit
85b859fb8d
@@ -151,10 +151,6 @@ void _exit(int status)
|
||||
nxsched_foreach(_up_dumponexit, NULL);
|
||||
#endif
|
||||
|
||||
/* Update scheduler parameters */
|
||||
|
||||
nxsched_suspend_scheduler(tcb);
|
||||
|
||||
/* Destroy the task at the head of the ready to run list. */
|
||||
|
||||
nxtask_exit();
|
||||
@@ -175,10 +171,6 @@ void _exit(int status)
|
||||
group_addrenv(tcb);
|
||||
#endif
|
||||
|
||||
/* Reset scheduler parameters */
|
||||
|
||||
nxsched_resume_scheduler(tcb);
|
||||
|
||||
/* Then switch contexts */
|
||||
|
||||
up_fullcontextrestore(tcb->xcp.regs);
|
||||
|
||||
@@ -149,10 +149,6 @@ void _exit(int status)
|
||||
nxsched_foreach(_up_dumponexit, NULL);
|
||||
#endif
|
||||
|
||||
/* Update scheduler parameters */
|
||||
|
||||
nxsched_suspend_scheduler(tcb);
|
||||
|
||||
/* Destroy the task at the head of the ready to run list. */
|
||||
|
||||
nxtask_exit();
|
||||
@@ -173,10 +169,6 @@ void _exit(int status)
|
||||
group_addrenv(tcb);
|
||||
#endif
|
||||
|
||||
/* Reset scheduler parameters */
|
||||
|
||||
nxsched_resume_scheduler(tcb);
|
||||
|
||||
/* Then switch contexts */
|
||||
|
||||
up_fullcontextrestore(tcb->xcp.regs);
|
||||
|
||||
Reference in New Issue
Block a user