diff options
| author | gfleury <gfleury@disroot.org> | 2025-01-03 12:37:45 +0200 |
|---|---|---|
| committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2025-01-29 02:32:36 +0100 |
| commit | e892a930736ba8f3c19a47dc0f46fec87da38313 (patch) | |
| tree | a73bbbe667ddb0e5157b576ee2c37b70903f3302 /sysdeps/htl | |
| parent | 56b25bfd60b736c7e7124b6fdd505a5622531a87 (diff) | |
| download | glibc-e892a930736ba8f3c19a47dc0f46fec87da38313.tar.xz glibc-e892a930736ba8f3c19a47dc0f46fec87da38313.zip | |
htl: move pthread_mutex_init into libc.
Message-ID: <20250103103750.870897-2-gfleury@disroot.org>
Diffstat (limited to 'sysdeps/htl')
| -rw-r--r-- | sysdeps/htl/libc-lockP.h | 2 | ||||
| -rw-r--r-- | sysdeps/htl/pthread-functions.h | 4 | ||||
| -rw-r--r-- | sysdeps/htl/pthreadP.h | 2 | ||||
| -rw-r--r-- | sysdeps/htl/timer_routines.c | 2 |
4 files changed, 2 insertions, 8 deletions
diff --git a/sysdeps/htl/libc-lockP.h b/sysdeps/htl/libc-lockP.h index 30801f935f..6c13382a21 100644 --- a/sysdeps/htl/libc-lockP.h +++ b/sysdeps/htl/libc-lockP.h @@ -117,7 +117,6 @@ extern int __pthread_atfork (void (*__prepare) (void), single-threaded processes. */ #if !defined(__NO_WEAK_PTHREAD_ALIASES) && !IS_IN (libpthread) # ifdef weak_extern -weak_extern (__pthread_mutex_init) weak_extern (__pthread_mutex_destroy) weak_extern (__pthread_mutex_lock) weak_extern (__pthread_mutex_trylock) @@ -137,7 +136,6 @@ weak_extern (__pthread_initialize) weak_extern (__pthread_atfork) weak_extern (__pthread_setcancelstate) # else -# pragma weak __pthread_mutex_init # pragma weak __pthread_mutex_destroy # pragma weak __pthread_mutex_lock # pragma weak __pthread_mutex_trylock diff --git a/sysdeps/htl/pthread-functions.h b/sysdeps/htl/pthread-functions.h index 97f4293367..54b773344d 100644 --- a/sysdeps/htl/pthread-functions.h +++ b/sysdeps/htl/pthread-functions.h @@ -23,8 +23,6 @@ void __pthread_exit (void *) __attribute__ ((__noreturn__)); int _pthread_mutex_destroy (pthread_mutex_t *); -int _pthread_mutex_init (pthread_mutex_t *, - const pthread_mutexattr_t *); int __pthread_mutex_lock (pthread_mutex_t *); int __pthread_mutex_trylock (pthread_mutex_t *); int __pthread_mutex_unlock (pthread_mutex_t *); @@ -50,8 +48,6 @@ struct pthread_functions { void (*ptr___pthread_exit) (void *) __attribute__ ((__noreturn__)); int (*ptr_pthread_mutex_destroy) (pthread_mutex_t *); - int (*ptr_pthread_mutex_init) (pthread_mutex_t *, - const pthread_mutexattr_t *); int (*ptr_pthread_mutex_lock) (pthread_mutex_t *); int (*ptr_pthread_mutex_trylock) (pthread_mutex_t *); int (*ptr_pthread_mutex_unlock) (pthread_mutex_t *); diff --git a/sysdeps/htl/pthreadP.h b/sysdeps/htl/pthreadP.h index 58bcd93006..bb17391cb3 100644 --- a/sysdeps/htl/pthreadP.h +++ b/sysdeps/htl/pthreadP.h @@ -32,6 +32,7 @@ extern void __pthread_init_static_tls (struct link_map *) attribute_hidden; /* These represent the interface used by glibc itself. */ extern int __pthread_mutex_init (pthread_mutex_t *__mutex, const pthread_mutexattr_t *__attr); +libc_hidden_proto (__pthread_mutex_init) extern int __pthread_mutex_destroy (pthread_mutex_t *__mutex); extern int __pthread_mutex_lock (pthread_mutex_t *__mutex); extern int __pthread_mutex_trylock (pthread_mutex_t *_mutex); @@ -162,7 +163,6 @@ hidden_proto (__pthread_detach) hidden_proto (__pthread_key_create) hidden_proto (__pthread_getspecific) hidden_proto (__pthread_setspecific) -hidden_proto (__pthread_mutex_init) hidden_proto (__pthread_mutex_destroy) hidden_proto (__pthread_mutex_lock) hidden_proto (__pthread_mutex_trylock) diff --git a/sysdeps/htl/timer_routines.c b/sysdeps/htl/timer_routines.c index 2e019182ab..2039e0ba2e 100644 --- a/sysdeps/htl/timer_routines.c +++ b/sysdeps/htl/timer_routines.c @@ -191,7 +191,7 @@ static void reinit_after_fork (void) { init_module (); - pthread_mutex_init (&__timer_mutex, 0); + __pthread_mutex_init (&__timer_mutex, 0); } |
