hartmannathan commented on code in PR #15048:
URL: https://github.com/apache/nuttx/pull/15048#discussion_r1869993448


##########
arch/arm/src/armv6-m/arm_schedulesigaction.c:
##########
@@ -96,7 +97,15 @@ void up_schedule_sigaction(struct tcb_s *tcb)
       (tcb->sigdeliver)(tcb);
       tcb->sigdeliver = NULL;
     }
-  else
+  else if (tcb == rtcb && ipsr != NVIC_IRQ_PENDSV)
+    {
+      /* Context switch should do in pendsv, for exception directy

Review Comment:
   ```suggestion
         /* Context switch should be done in pendsv, for exception directly
   ```



##########
arch/arm/src/armv8-m/arm_schedulesigaction.c:
##########
@@ -97,7 +98,15 @@ void up_schedule_sigaction(struct tcb_s *tcb)
       (tcb->sigdeliver)(tcb);
       tcb->sigdeliver = NULL;
     }
-  else
+  else if (tcb == rtcb && ipsr != NVIC_IRQ_PENDSV)
+    {
+      /* Context switch should do in pendsv, for exception directy
+       * last regs is not saved tcb->xcp.regs.

Review Comment:
   ditto



##########
arch/arm/src/armv7-m/arm_schedulesigaction.c:
##########
@@ -97,7 +98,15 @@ void up_schedule_sigaction(struct tcb_s *tcb)
       (tcb->sigdeliver)(tcb);
       tcb->sigdeliver = NULL;
     }
-  else
+  else if (tcb == rtcb && ipsr != NVIC_IRQ_PENDSV)
+    {
+      /* Context switch should do in pendsv, for exception directy
+       * last regs is not saved tcb->xcp.regs.

Review Comment:
   ditto



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to