Skip to content

Commit d77cb8a

Browse files
hujun260xiaoxiang781216
authored andcommitted
sched: fix nxsched_process_delivered did not call hook
Signed-off-by: hujun5 <[email protected]>
1 parent 6ff7c84 commit d77cb8a

File tree

3 files changed

+21
-0
lines changed

3 files changed

+21
-0
lines changed

arch/arm/src/armv7-a/arm_smpcall.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,16 @@
6868

6969
int arm_smp_sched_handler(int irq, void *context, void *arg)
7070
{
71+
struct tcb_s *tcb;
7172
int cpu = this_cpu();
7273

74+
tcb = current_task(cpu);
75+
nxsched_suspend_scheduler(tcb);
7376
nxsched_process_delivered(cpu);
77+
tcb = current_task(cpu);
78+
nxsched_resume_scheduler(tcb);
79+
80+
UNUSED(tcb);
7481
return OK;
7582
}
7683

arch/arm/src/armv7-r/arm_smpcall.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,16 @@
6868

6969
int arm_smp_sched_handler(int irq, void *context, void *arg)
7070
{
71+
struct tcb_s *tcb;
7172
int cpu = this_cpu();
7273

74+
tcb = current_task(cpu);
75+
nxsched_suspend_scheduler(tcb);
7376
nxsched_process_delivered(cpu);
77+
tcb = current_task(cpu);
78+
nxsched_resume_scheduler(tcb);
79+
80+
UNUSED(tcb);
7481
return OK;
7582
}
7683

arch/arm64/src/common/arm64_smpcall.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,16 @@
6767

6868
int arm64_smp_sched_handler(int irq, void *context, void *arg)
6969
{
70+
struct tcb_s *tcb;
7071
int cpu = this_cpu();
7172

73+
tcb = current_task(cpu);
74+
nxsched_suspend_scheduler(tcb);
7275
nxsched_process_delivered(cpu);
76+
tcb = current_task(cpu);
77+
nxsched_resume_scheduler(tcb);
78+
79+
UNUSED(tcb);
7380

7481
return OK;
7582
}

0 commit comments

Comments
 (0)