mirror of
https://github.com/apache/nuttx.git
synced 2026-05-23 14:58:13 +08:00
arch/risc-v: remove duplicated nxsched_switch_context() call
The nxsched_switch_context() function should only be called
when a task switch actually occurs. The RISC-V architecture
already performs this call in riscv_perform_syscall(),
so this PR removed the redundant nxsched_switch_context() call in
up_switch_context().
Signed-off-by: Chengdong Wang <wangchengdong@lixiang.com>
This commit is contained in:
committed by
Xiang Xiao
parent
fcb96babc5
commit
fca1010a5b
@@ -80,12 +80,6 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
|
||||
|
||||
else
|
||||
{
|
||||
/* Update scheduler parameters */
|
||||
|
||||
nxsched_switch_context(rtcb, tcb);
|
||||
|
||||
/* Then switch contexts */
|
||||
|
||||
riscv_switchcontext();
|
||||
|
||||
/* riscv_switchcontext forces a context switch to the task at the
|
||||
|
||||
Reference in New Issue
Block a user