Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x86_64: fix regression https://github.com/apache/nuttx/pull/15651 #15670

Merged
merged 1 commit into from
Jan 23, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 1 addition & 9 deletions arch/x86_64/src/intel64/intel64_handlers.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ static uint64_t *common_handler(int irq, uint64_t *regs)
struct tcb_s **running_task = &g_running_tasks[this_cpu()];
struct tcb_s *tcb;

(*running_task)->xcp.regs = regs;

/* Current regs non-zero indicates that we are processing an interrupt;
* g_current_regs is also used to manage interrupt level context switches.
*
Expand Down Expand Up @@ -126,14 +124,8 @@ static uint64_t *common_handler(int irq, uint64_t *regs)
/* Clear irq flag */

up_set_interrupt_context(false);
regs = tcb->xcp.regs;

/* (*running_task)->xcp.regs is about to become invalid
* and will be marked as NULL to avoid misusage.
*/

(*running_task)->xcp.regs = NULL;
return regs;
return tcb->xcp.regs;
}
#endif

Expand Down
Loading