linux(4): Change clone syscall definition to match Linux actual one.

Differential revision:	https://reviews.freebsd.org/D31473
MFC after:		2 weeks
This commit is contained in:
Dmitry Chagin 2021-08-12 11:46:36 +03:00
parent de8374df28
commit f1c450492f
6 changed files with 28 additions and 28 deletions

View File

@ -422,10 +422,10 @@
56 AUE_RFORK STD {
int linux_clone(
l_ulong flags,
void *stack,
void *parent_tidptr,
void *child_tidptr,
void *tls
l_ulong stack,
l_int *parent_tidptr,
l_int *child_tidptr,
l_ulong tls
);
}
57 AUE_FORK STD {

View File

@ -642,11 +642,11 @@
}
120 AUE_RFORK STD {
int linux_clone(
l_int flags,
void *stack,
void *parent_tidptr,
void *tls,
void *child_tidptr
l_ulong flags,
l_ulong stack,
l_int *parent_tidptr,
l_ulong tls,
l_int *child_tidptr
);
}
121 AUE_SYSCTL STD {

View File

@ -508,11 +508,11 @@
}
120 AUE_RFORK STD {
int linux_clone(
l_int flags,
void *stack,
void *parent_tidptr,
void *tls,
void * child_tidptr
l_ulong flags,
l_ulong stack,
l_int *parent_tidptr,
l_ulong tls,
l_int *child_tidptr
);
}
121 AUE_SYSCTL STD {

View File

@ -1316,10 +1316,10 @@
220 AUE_RFORK STD {
int linux_clone(
l_ulong flags,
void *stack,
void *parent_tidptr,
void *tls,
void *child_tidptr
l_ulong stack,
l_int *parent_tidptr,
l_ulong tls,
l_int *child_tidptr
);
}
221 AUE_EXECVE STD {

View File

@ -205,10 +205,10 @@ linux_clone_proc(struct thread *td, struct linux_clone_args *args)
* stack. This is what normal fork() does, so we just keep tf_rsp arg
* intact.
*/
linux_set_upcall(td2, PTROUT(args->stack));
linux_set_upcall(td2, args->stack);
if (args->flags & LINUX_CLONE_SETTLS)
linux_set_cloned_tls(td2, args->tls);
linux_set_cloned_tls(td2, PTRIN(args->tls));
/*
* If CLONE_PARENT is set, then the parent of the new process will be
@ -253,7 +253,7 @@ linux_clone_thread(struct thread *td, struct linux_clone_args *args)
return (EINVAL);
/* Threads should be created with own stack */
if (args->stack == NULL)
if (PTRIN(args->stack) == NULL)
return (EINVAL);
p = td->td_proc;
@ -290,7 +290,7 @@ linux_clone_thread(struct thread *td, struct linux_clone_args *args)
KASSERT(em != NULL, ("clone_thread: emuldata not found.\n"));
if (args->flags & LINUX_CLONE_SETTLS)
linux_set_cloned_tls(newtd, args->tls);
linux_set_cloned_tls(newtd, PTRIN(args->tls));
if (args->flags & LINUX_CLONE_CHILD_SETTID)
em->child_set_tid = args->child_tidptr;
@ -304,7 +304,7 @@ linux_clone_thread(struct thread *td, struct linux_clone_args *args)
cpu_thread_clean(newtd);
linux_set_upcall(newtd, PTROUT(args->stack));
linux_set_upcall(newtd, args->stack);
PROC_LOCK(p);
p->p_flag |= P_HADTHREADS;

View File

@ -659,11 +659,11 @@
}
120 AUE_RFORK STD {
int linux_clone(
l_int flags,
void *stack,
void *parent_tidptr,
void *tls,
void *child_tidptr
l_ulong flags,
l_ulong stack,
l_int *parent_tidptr,
l_ulong tls,
l_int *child_tidptr
);
}
121 AUE_SYSCTL STD {