arch/x86_64/intel64: remove unnecessary nested syscalls logic

remove unnecessary nested syscalls logic, it's already handled different way
This commit is contained in:
p-szafonimateusz 2024-11-27 14:41:58 +01:00 committed by Alan C. Assis
parent c02dba9a0d
commit 908ac756ea
2 changed files with 0 additions and 22 deletions

View file

@ -545,15 +545,6 @@ struct xcptcontext
uint64_t *regs;
#ifdef CONFIG_LIB_SYSCALL
/* The following array holds information needed to return from each nested
* system call.
*/
uint8_t nsyscalls;
struct xcpt_syscall_s syscall[CONFIG_SYS_NNEST];
#endif
#ifdef CONFIG_ARCH_ADDRENV
# ifdef CONFIG_ARCH_KERNEL_STACK
/* In this configuration, all syscalls execute from an internal kernel

View file

@ -296,14 +296,6 @@ uint64_t *x86_64_syscall(uint64_t *regs)
struct tcb_s *rtcb = nxsched_self();
syscall_stub_t stub = (syscall_stub_t)g_stublookup[nbr];
DEBUGASSERT(nbr < SYS_nsyscalls);
DEBUGASSERT(rtcb->xcp.nsyscalls < CONFIG_SYS_NNEST);
/* Setup nested syscall */
rtcb->xcp.syscall[rtcb->xcp.nsyscalls].sysreturn = regs[REG_RCX];
rtcb->xcp.nsyscalls += 1;
#ifdef CONFIG_ARCH_KERNEL_STACK
/* Store reference to user RSP for signals */
@ -314,11 +306,6 @@ uint64_t *x86_64_syscall(uint64_t *regs)
ret = stub(nbr, arg1, arg2, arg3, arg4, arg5, arg6);
/* Setup return from nested syscall */
rtcb->xcp.nsyscalls -= 1;
regs[REG_RCX] = rtcb->xcp.syscall[rtcb->xcp.nsyscalls].sysreturn;
break;
}
}