set tls block base to parent if not specified
This commit is contained in:
@@ -493,11 +493,12 @@ SYSCALL_DECLARE(clone)
|
|||||||
dkprintf("clone_flags & CLONE_SETTLS: 0x%lX\n",
|
dkprintf("clone_flags & CLONE_SETTLS: 0x%lX\n",
|
||||||
(unsigned long)aal_mc_syscall_arg4(ctx));
|
(unsigned long)aal_mc_syscall_arg4(ctx));
|
||||||
|
|
||||||
new->thread.tlsblock_base
|
new->thread.tlsblock_base =
|
||||||
= (unsigned long)aal_mc_syscall_arg4(ctx);
|
(unsigned long)aal_mc_syscall_arg4(ctx);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
new->thread.tlsblock_base = 0;
|
new->thread.tlsblock_base =
|
||||||
|
cpu_local_var(current)->thread.tlsblock_base;
|
||||||
}
|
}
|
||||||
|
|
||||||
aal_mc_syscall_ret(new->uctx) = 0;
|
aal_mc_syscall_ret(new->uctx) = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user