irq: use up_interrupt_context to replace up_current_regs

Signed-off-by: hujun5 <hujun5@xiaomi.com>
This commit is contained in:
hujun5 2024-06-25 21:33:35 +08:00 committed by Xiang Xiao
parent 4ecb6efee8
commit d573952790
10 changed files with 10 additions and 35 deletions

View File

@ -61,7 +61,7 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
/* Are we in an interrupt handler? */
if (up_current_regs())
if (up_interrupt_context())
{
/* Update scheduler parameters */

View File

@ -61,7 +61,7 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
/* Are we in an interrupt handler? */
if (up_current_regs())
if (up_interrupt_context())
{
/* Yes, then we have to do things differently.
* Just copy the current_regs into the OLD rtcb.

View File

@ -63,7 +63,7 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
/* Are we in an interrupt handler? */
if (up_current_regs())
if (up_interrupt_context())
{
/* Yes, then we have to do things differently.
* Just copy the current_regs into the OLD rtcb.

View File

@ -64,7 +64,7 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
/* Are we in an interrupt handler? */
if (up_current_regs())
if (up_interrupt_context())
{
/* Yes, then we have to do things differently.
* Just copy the current_regs into the OLD rtcb.

View File

@ -65,7 +65,7 @@ void up_switch_context(struct tcb_s *tcb, struct tcb_s *rtcb)
/* Are we in an interrupt handler? */
if (up_current_regs())
if (up_interrupt_context())
{
/* Yes, then we have to do things differently.
* Just copy the g_current_regs into the OLD rtcb.

View File

@ -155,12 +155,7 @@ void board_crashdump(uintptr_t sp, struct tcb_s *tcb,
pdump->info.pid = tcb->pid;
/* If current_regs is not NULL then we are in an interrupt context
* and the user context is in current_regs else we are running in
* the users context
*/
if (up_current_regs())
if (up_interrupt_context())
{
#if CONFIG_ARCH_INTERRUPTSTACK > 3
pdump->info.stacks.interrupt.sp = sp;

View File

@ -426,12 +426,7 @@ void board_crashdump(uintptr_t sp, struct tcb_s *tcb,
pdump->info.pid = tcb->pid;
/* If current_regs is not NULL then we are in an interrupt context
* and the user context is in current_regs else we are running in
* the users context
*/
if (up_current_regs())
if (up_interrupt_context())
{
pdump->info.stacks.interrupt.sp = sp;
pdump->info.flags |= (REGS_PRESENT | USERSTACK_PRESENT |

View File

@ -426,12 +426,7 @@ void board_crashdump(uintptr_t sp, struct tcb_s *tcb,
pdump->info.pid = tcb->pid;
/* If current_regs is not NULL then we are in an interrupt context
* and the user context is in current_regs else we are running in
* the users context
*/
if (up_current_regs())
if (up_interrupt_context())
{
pdump->info.stacks.interrupt.sp = sp;
pdump->info.flags |= (REGS_PRESENT | USERSTACK_PRESENT |

View File

@ -380,12 +380,7 @@ void board_crashdump(uintptr_t sp, struct tcb_s *tcb,
pdump->info.pid = tcb->pid;
/* If current_regs is not NULL then we are in an interrupt context
* and the user context is in current_regs else we are running in
* the users context
*/
if (up_current_regs())
if (up_interrupt_context())
{
pdump->info.stacks.interrupt.sp = sp;
pdump->info.flags |= (REGS_PRESENT | USERSTACK_PRESENT |

View File

@ -378,12 +378,7 @@ void board_crashdump(uintptr_t sp, struct tcb_s *tcb,
pdump->info.pid = tcb->pid;
/* If current_regs is not NULL then we are in an interrupt context
* and the user context is in current_regs else we are running in
* the users context
*/
if (up_current_regs())
if (up_interrupt_context())
{
pdump->info.stacks.interrupt.sp = sp;
pdump->info.flags |= (REGS_PRESENT | USERSTACK_PRESENT |