summaryrefslogtreecommitdiff
path: root/src/thread/forkall.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2011-09-18 10:14:37 -0400
committerRich Felker <dalias@aerifal.cx>2011-09-18 10:14:37 -0400
commit3f72cdac73030761120cf32aeef44e7d03e2f1fa (patch)
treed52dde9adbb8386100d98371d4e954fb88af2c41 /src/thread/forkall.c
parent455fc98389fac09d8cf7ec4cde310a5b7ca47485 (diff)
downloadmusl-3f72cdac73030761120cf32aeef44e7d03e2f1fa.tar.gz
overhaul clone syscall wrapping
several things are changed. first, i have removed the old __uniclone function signature and replaced it with the "standard" linux __clone/clone signature. this was necessary to expose clone to applications anyway, and it makes it easier to port __clone to new archs, since it's now testable independently of pthread_create. secondly, i have removed all references to the ugly ldt descriptor structure (i386 only) from the c code and pthread structure. in places where it is needed, it is now created on the stack just when it's needed, in assembly code. thus, the i386 __clone function takes the desired thread pointer as its argument, rather than an ldt descriptor pointer, just like on all other sane archs. this should not affect applications since there is really no way an application can use clone with threads/tls in a way that doesn't horribly conflict with and clobber the underlying implementation's use. applications are expected to use clone only for creating actual processes, possibly with new namespace features and whatnot.
Diffstat (limited to 'src/thread/forkall.c')
-rw-r--r--src/thread/forkall.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/thread/forkall.c b/src/thread/forkall.c
index 403818ec..6810ea50 100644
--- a/src/thread/forkall.c
+++ b/src/thread/forkall.c
@@ -1,3 +1,4 @@
+#if 0
#include "pthread_impl.h"
#include <setjmp.h>
@@ -64,3 +65,4 @@ pid_t forkall()
__synccall(do_forkall, &c);
return c.pid;
}
+#endif