Skip to content

Commit

Permalink
arm: we should use tcb->xcp.regs instead of up_current_regs() as the …
Browse files Browse the repository at this point in the history
…basis for judging whether to call restore_critical_section.

This commit fixes the regression from apache#13444

Signed-off-by: hujun5 <hujun5@xiaomi.com>
  • Loading branch information
hujun260 authored and masayuki2009 committed Sep 25, 2024
1 parent 542e2ba commit efdb432
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion arch/arm/src/armv6-m/arm_svcall.c
Original file line number Diff line number Diff line change
@@ -474,7 +474,7 @@ int arm_svcall(int irq, void *context, void *arg)
# endif
#endif

if (regs != up_current_regs())
if (regs != tcb->xcp.regs)
{
restore_critical_section(this_task(), this_cpu());
}
2 changes: 1 addition & 1 deletion arch/arm/src/armv7-m/arm_svcall.c
Original file line number Diff line number Diff line change
@@ -483,7 +483,7 @@ int arm_svcall(int irq, void *context, void *arg)
# endif
#endif

if (regs != up_current_regs())
if (regs != tcb->xcp.regs)
{
restore_critical_section(this_task(), this_cpu());
}
2 changes: 1 addition & 1 deletion arch/arm/src/armv8-m/arm_svcall.c
Original file line number Diff line number Diff line change
@@ -484,7 +484,7 @@ int arm_svcall(int irq, void *context, void *arg)
# endif
#endif

if (regs != up_current_regs())
if (regs != tcb->xcp.regs)
{
restore_critical_section(this_task(), this_cpu());
}

0 comments on commit efdb432

Please sign in to comment.