commit-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[hurd,commited 1/8] htl: move pthread_mutexattr_init into libc.


From: Samuel Thibault
Subject: [hurd,commited 1/8] htl: move pthread_mutexattr_init into libc.
Date: Thu, 2 Jan 2025 01:56:19 +0100

From: gfleury <gfleury@disroot.org>

Message-ID: <20241231134909.1166440-2-gfleury@disroot.org>
---
 htl/Makefile                                | 2 +-
 htl/Versions                                | 4 +++-
 sysdeps/htl/libc-lockP.h                    | 5 +----
 sysdeps/htl/pthreadP.h                      | 1 -
 sysdeps/mach/hurd/htl/pt-mutexattr-init.c   | 1 +
 sysdeps/mach/hurd/i386/libc.abilist         | 1 +
 sysdeps/mach/hurd/i386/libpthread.abilist   | 1 -
 sysdeps/mach/hurd/x86_64/libc.abilist       | 1 +
 sysdeps/mach/hurd/x86_64/libpthread.abilist | 1 -
 9 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/htl/Makefile b/htl/Makefile
index 447ec4722f..5d1f7af378 100644
--- a/htl/Makefile
+++ b/htl/Makefile
@@ -55,7 +55,6 @@ libpthread-routines := \
   pt-testcancel \
   pt-cancel \
   pt-mutexattr-destroy \
-  pt-mutexattr-init \
   pt-mutexattr-getprioceiling \
   pt-mutexattr-getprotocol \
   pt-mutexattr-getpshared \
@@ -201,6 +200,7 @@ routines := \
   pt-condattr-setpshared \
   pt-getschedparam \
   pt-mutex-checklocked \
+  pt-mutexattr-init \
   pt-nthreads \
   pt-pthread_self \
   pt-self pt-equal \
diff --git a/htl/Versions b/htl/Versions
index 1492a2a1ca..ae0e794919 100644
--- a/htl/Versions
+++ b/htl/Versions
@@ -38,6 +38,7 @@ libc {
     pthread_condattr_getpshared;
     pthread_condattr_setclock;
     pthread_condattr_setpshared;
+    pthread_mutexattr_init;
     pthread_sigmask;
   }
 
@@ -114,6 +115,7 @@ libc {
     __pthread_condattr_init;
     __pthread_default_condattr;
     __pthread_mutex_checklocked;
+    __pthread_mutexattr_init;
     __pthread_sigstate;
     __pthread_sigstate_destroy;
     __pthread_sigmask;
@@ -176,7 +178,7 @@ libpthread {
 
     pthread_mutexattr_destroy; pthread_mutexattr_getprioceiling;
     pthread_mutexattr_getprotocol; pthread_mutexattr_getpshared;
-    pthread_mutexattr_gettype; pthread_mutexattr_init;
+    pthread_mutexattr_gettype;
     pthread_mutexattr_setprioceiling; pthread_mutexattr_setprotocol;
     pthread_mutexattr_setpshared; pthread_mutexattr_settype;
 
diff --git a/sysdeps/htl/libc-lockP.h b/sysdeps/htl/libc-lockP.h
index 54ab845664..404bd9f05a 100644
--- a/sysdeps/htl/libc-lockP.h
+++ b/sysdeps/htl/libc-lockP.h
@@ -85,6 +85,7 @@ extern int __pthread_mutex_lock (pthread_mutex_t *__mutex);
 extern int __pthread_mutex_unlock (pthread_mutex_t *__mutex);
 
 extern int __pthread_mutexattr_init (pthread_mutexattr_t *__attr);
+libc_hidden_proto (__pthread_mutexattr_init)
 
 extern int __pthread_mutexattr_destroy (pthread_mutexattr_t *__attr);
 
@@ -113,8 +114,6 @@ extern int __pthread_atfork (void (*__prepare) (void),
                             void (*__parent) (void),
                             void (*__child) (void));
 
-
-
 /* Make the pthread functions weak so that we can elide them from
    single-threaded processes.  */
 #if !defined(__NO_WEAK_PTHREAD_ALIASES) && !IS_IN (libpthread)
@@ -124,7 +123,6 @@ weak_extern (__pthread_mutex_destroy)
 weak_extern (__pthread_mutex_lock)
 weak_extern (__pthread_mutex_trylock)
 weak_extern (__pthread_mutex_unlock)
-weak_extern (__pthread_mutexattr_init)
 weak_extern (__pthread_mutexattr_destroy)
 weak_extern (__pthread_mutexattr_settype)
 weak_extern (__pthread_rwlock_init)
@@ -147,7 +145,6 @@ weak_extern (__pthread_setcancelstate)
 #  pragma weak __pthread_mutex_lock
 #  pragma weak __pthread_mutex_trylock
 #  pragma weak __pthread_mutex_unlock
-#  pragma weak __pthread_mutexattr_init
 #  pragma weak __pthread_mutexattr_destroy
 #  pragma weak __pthread_mutexattr_settype
 #  pragma weak __pthread_rwlock_destroy
diff --git a/sysdeps/htl/pthreadP.h b/sysdeps/htl/pthreadP.h
index fa47648a96..b32c41b1d0 100644
--- a/sysdeps/htl/pthreadP.h
+++ b/sysdeps/htl/pthreadP.h
@@ -38,7 +38,6 @@ extern int __pthread_mutex_trylock (pthread_mutex_t *_mutex);
 extern int __pthread_mutex_timedlock (pthread_mutex_t *__mutex,
      const struct timespec *__abstime);
 extern int __pthread_mutex_unlock (pthread_mutex_t *__mutex);
-extern int __pthread_mutexattr_init (pthread_mutexattr_t *attr);
 extern int __pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind);
 
 extern int __pthread_cond_init (pthread_cond_t *cond,
diff --git a/sysdeps/mach/hurd/htl/pt-mutexattr-init.c 
b/sysdeps/mach/hurd/htl/pt-mutexattr-init.c
index e248f68f47..0464dcddca 100644
--- a/sysdeps/mach/hurd/htl/pt-mutexattr-init.c
+++ b/sysdeps/mach/hurd/htl/pt-mutexattr-init.c
@@ -38,4 +38,5 @@ __pthread_mutexattr_init (pthread_mutexattr_t *attrp)
   *attrp = dfl_attr;
   return 0;
 }
+hidden_def (__pthread_mutexattr_init)
 weak_alias (__pthread_mutexattr_init, pthread_mutexattr_init)
diff --git a/sysdeps/mach/hurd/i386/libc.abilist 
b/sysdeps/mach/hurd/i386/libc.abilist
index b48fa38edf..9a11c29266 100644
--- a/sysdeps/mach/hurd/i386/libc.abilist
+++ b/sysdeps/mach/hurd/i386/libc.abilist
@@ -63,6 +63,7 @@ GLIBC_2.12 pthread_condattr_setclock F
 GLIBC_2.12 pthread_condattr_setpshared F
 GLIBC_2.12 pthread_equal F
 GLIBC_2.12 pthread_getschedparam F
+GLIBC_2.12 pthread_mutexattr_init F
 GLIBC_2.12 pthread_self F
 GLIBC_2.12 pthread_setschedparam F
 GLIBC_2.12 pthread_sigmask F
diff --git a/sysdeps/mach/hurd/i386/libpthread.abilist 
b/sysdeps/mach/hurd/i386/libpthread.abilist
index f90794bc5c..7e4c7ff6d0 100644
--- a/sysdeps/mach/hurd/i386/libpthread.abilist
+++ b/sysdeps/mach/hurd/i386/libpthread.abilist
@@ -55,7 +55,6 @@ GLIBC_2.12 pthread_mutexattr_getprioceiling F
 GLIBC_2.12 pthread_mutexattr_getprotocol F
 GLIBC_2.12 pthread_mutexattr_getpshared F
 GLIBC_2.12 pthread_mutexattr_gettype F
-GLIBC_2.12 pthread_mutexattr_init F
 GLIBC_2.12 pthread_mutexattr_setprioceiling F
 GLIBC_2.12 pthread_mutexattr_setprotocol F
 GLIBC_2.12 pthread_mutexattr_setpshared F
diff --git a/sysdeps/mach/hurd/x86_64/libc.abilist 
b/sysdeps/mach/hurd/x86_64/libc.abilist
index 1cd5f99297..191446e2f8 100644
--- a/sysdeps/mach/hurd/x86_64/libc.abilist
+++ b/sysdeps/mach/hurd/x86_64/libc.abilist
@@ -1551,6 +1551,7 @@ GLIBC_2.38 pthread_mutex_destroy F
 GLIBC_2.38 pthread_mutex_init F
 GLIBC_2.38 pthread_mutex_lock F
 GLIBC_2.38 pthread_mutex_unlock F
+GLIBC_2.38 pthread_mutexattr_init F
 GLIBC_2.38 pthread_self F
 GLIBC_2.38 pthread_setcancelstate F
 GLIBC_2.38 pthread_setcanceltype F
diff --git a/sysdeps/mach/hurd/x86_64/libpthread.abilist 
b/sysdeps/mach/hurd/x86_64/libpthread.abilist
index 6262dfa86c..26cb3e64e6 100644
--- a/sysdeps/mach/hurd/x86_64/libpthread.abilist
+++ b/sysdeps/mach/hurd/x86_64/libpthread.abilist
@@ -80,7 +80,6 @@ GLIBC_2.38 pthread_mutexattr_getpshared F
 GLIBC_2.38 pthread_mutexattr_getrobust F
 GLIBC_2.38 pthread_mutexattr_getrobust_np F
 GLIBC_2.38 pthread_mutexattr_gettype F
-GLIBC_2.38 pthread_mutexattr_init F
 GLIBC_2.38 pthread_mutexattr_setprioceiling F
 GLIBC_2.38 pthread_mutexattr_setprotocol F
 GLIBC_2.38 pthread_mutexattr_setpshared F
-- 
2.45.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]