-#include <arch/abi.h>
#include <lunaix/exec.h>
#include <lunaix/fs.h>
#include <lunaix/load.h>
#include <lunaix/syscall.h>
#include <lunaix/syscall_utils.h>
+#include <sys/abi.h>
+#include <sys/mm/mempart.h>
+
#include <klibc/string.h>
void
if (container->vms_mnt == VMS_SELF) {
// we are loading executable into current addr space
- ptr_t ustack = USTACK_TOP;
+ ptr_t ustack = USR_STACK_END;
size_t argv_len = 0, envp_len = 0;
ptr_t argv_ptr = 0, envp_ptr = 0;
// we will jump to new entry point (_u_start) upon syscall's
// return so execve 'will not return' from the perspective of it's invoker
- volatile struct exec_param* execp = __current->intr_ctx->execp;
- execp->esp = container.stack_top;
- execp->eip = container.exe.entry;
+ eret_target(__current) = container.exe.entry;
+ eret_stack(__current) = container.stack_top;
// these become meaningless once execved!
__current->ustack_top = 0;