diff --git a/sys/amd64/amd64/vm_machdep.c b/sys/amd64/amd64/vm_machdep.c index 9e77ac7af2d..36001bc5b5b 100644 --- a/sys/amd64/amd64/vm_machdep.c +++ b/sys/amd64/amd64/vm_machdep.c @@ -617,16 +617,6 @@ int cpu_set_upcall(struct thread *td, void (*entry)(void *), void *arg, stack_t *stack) { - - /* - * Do any extra cleaning that needs to be done. - * The thread may have optional components - * that are not present in a fresh thread. - * This may be a recycled thread so make it look - * as though it's newly allocated. - */ - cpu_thread_clean(td); - #ifdef COMPAT_FREEBSD32 if (SV_PROC_FLAG(td->td_proc, SV_ILP32)) { /* diff --git a/sys/compat/linux/linux_fork.c b/sys/compat/linux/linux_fork.c index 4ce3bc192b4..1c9189162a0 100644 --- a/sys/compat/linux/linux_fork.c +++ b/sys/compat/linux/linux_fork.c @@ -301,8 +301,6 @@ linux_clone_thread(struct thread *td, struct l_clone_args *args) else em->child_clear_tid = NULL; - cpu_thread_clean(newtd); - linux_set_upcall(newtd, args->stack); PROC_LOCK(p); diff --git a/sys/i386/i386/vm_machdep.c b/sys/i386/i386/vm_machdep.c index e05791967fb..d252438dc18 100644 --- a/sys/i386/i386/vm_machdep.c +++ b/sys/i386/i386/vm_machdep.c @@ -492,16 +492,6 @@ int cpu_set_upcall(struct thread *td, void (*entry)(void *), void *arg, stack_t *stack) { - - /* - * Do any extra cleaning that needs to be done. - * The thread may have optional components - * that are not present in a fresh thread. - * This may be a recycled thread so make it look - * as though it's newly allocated. - */ - cpu_thread_clean(td); - /* * Set the trap frame to point at the beginning of the entry * function.