diff options
author | Florian Weimer <fweimer@redhat.com> | 2021-04-21 19:49:50 +0200 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2021-04-21 19:49:50 +0200 |
commit | 3fec7f18bfcb7044e813a12e19c3c98eb8387e26 (patch) | |
tree | 63320bd00d52f0437c4f8676fbff561311dfdb8f /nptl/libc_pthread_init.c | |
parent | 4647ce82c733d1453611e35236b786ecd7faf598 (diff) | |
download | glibc-3fec7f18bfcb7044e813a12e19c3c98eb8387e26.zip glibc-3fec7f18bfcb7044e813a12e19c3c98eb8387e26.tar.gz glibc-3fec7f18bfcb7044e813a12e19c3c98eb8387e26.tar.bz2 |
nptl: Move pthread_once and __pthread_once into libc
And also the fork generation counter, __fork_generation. This
eliminates the need for __fork_generation_pointer.
call_once remains in libpthread and calls the exported __pthread_once
symbol.
pthread_once and __pthread_once have been moved using
scripts/move-symbol-to-libc.py.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Diffstat (limited to 'nptl/libc_pthread_init.c')
-rw-r--r-- | nptl/libc_pthread_init.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/nptl/libc_pthread_init.c b/nptl/libc_pthread_init.c index 4de182b..b67a69f 100644 --- a/nptl/libc_pthread_init.c +++ b/nptl/libc_pthread_init.c @@ -28,9 +28,6 @@ #include <ldsodefs.h> -unsigned long int *__fork_generation_pointer; - - #ifdef TLS_MULTIPLE_THREADS_IN_TCB void #else @@ -38,12 +35,9 @@ extern int __libc_multiple_threads attribute_hidden; int * #endif -__libc_pthread_init (unsigned long int *ptr, void (*reclaim) (void), +__libc_pthread_init (void (*reclaim) (void), const struct pthread_functions *functions) { - /* Remember the pointer to the generation counter in libpthread. */ - __fork_generation_pointer = ptr; - /* Called by a child after fork. */ __register_atfork (NULL, NULL, reclaim, NULL); |