]> sourceware.org Git - glibc.git/commitdiff
htl: move pthread_setcanceltype into libc.
authorgfleury <gfleury@disroot.org>
Fri, 3 Jan 2025 10:37:50 +0000 (12:37 +0200)
committerSamuel Thibault <samuel.thibault@ens-lyon.org>
Wed, 29 Jan 2025 01:32:36 +0000 (02:32 +0100)
Message-ID: <20250103103750.870897-7-gfleury@disroot.org>

htl/Makefile
htl/Versions
htl/forward.c
htl/pt-initialize.c
htl/pt-setcanceltype.c
sysdeps/htl/pthread-functions.h
sysdeps/htl/pthreadP.h
sysdeps/mach/hurd/i386/libc.abilist
sysdeps/mach/hurd/i386/libpthread.abilist
sysdeps/mach/hurd/x86_64/libpthread.abilist

index 5b0b6023b083733627154c74d052edd1183ba9d5..d4418ab9f91b76dfe627b184d31f445cbe3c1cda 100644 (file)
@@ -51,7 +51,6 @@ libpthread-routines := \
   pt-spin-inlines \
   pt-cleanup \
   pt-setcancelstate \
-  pt-setcanceltype \
   pt-testcancel \
   pt-cancel \
   pt-mutex-transfer-np \
@@ -204,6 +203,7 @@ routines := \
   pt-nthreads \
   pt-pthread_self \
   pt-self pt-equal \
+  pt-setcanceltype \
   pt-setschedparam \
   pt-sigmask \
   pt-sigstate \
index 2ebf554cfa0a84c710f2d55f5cdb30aec8b9b503..6801d121821ddc2eed60d6f70fd7fad4163c8094 100644 (file)
@@ -56,6 +56,7 @@ libc {
     pthread_mutexattr_setprotocol;
     pthread_mutexattr_setpshared;
     pthread_mutexattr_settype;
+    pthread_setcanceltype;
     pthread_sigmask;
   }
 
@@ -231,7 +232,7 @@ libpthread {
     pthread_rwlockattr_destroy; pthread_rwlockattr_getpshared;
     pthread_rwlockattr_init; pthread_rwlockattr_setpshared;
 
-    pthread_setcancelstate; pthread_setcanceltype;
+    pthread_setcancelstate;
     pthread_setconcurrency;
     pthread_setschedprio; pthread_setspecific;
 
index 636902919ebefc8752cad809e77125fa25d993af..9455df7316b8f0066f6956572373c0352e725956 100644 (file)
@@ -62,7 +62,5 @@ FORWARD (__pthread_setcancelstate, (int state, int *oldstate),
         (state, oldstate), 0)
 strong_alias (__pthread_setcancelstate, pthread_setcancelstate);
 
-FORWARD (pthread_setcanceltype, (int type, int *oldtype), (type, oldtype), 0)
-
 FORWARD2 (__pthread_get_cleanup_stack, struct __pthread_cancelation_handler **,
          (void), (), return &__pthread_cleanup_stack);
index 5854bc496764f1de4d254bc14a077485fe019152..eba9e12d73e5d8d428461479b6882839c8bd6102 100644 (file)
@@ -29,7 +29,6 @@
 static const struct pthread_functions pthread_functions = {
   .ptr___pthread_exit = __pthread_exit,
   .ptr___pthread_setcancelstate = __pthread_setcancelstate,
-  .ptr_pthread_setcanceltype = __pthread_setcanceltype,
   .ptr___pthread_get_cleanup_stack = __pthread_get_cleanup_stack,
   .ptr_pthread_once = __pthread_once,
   .ptr_pthread_rwlock_rdlock = __pthread_rwlock_rdlock,
index f9474f9c39208060105d7f8c9071d7d842a29c6a..0b76fbfbd69aec6ce695f3b389d36f674fa97178 100644 (file)
@@ -17,7 +17,7 @@
    <https://www.gnu.org/licenses/>.  */
 
 #include <pthread.h>
-
+#include <shlib-compat.h>
 #include <pt-internal.h>
 
 int
@@ -42,5 +42,9 @@ __pthread_setcanceltype (int type, int *oldtype)
 
   return 0;
 }
+libc_hidden_def (__pthread_setcanceltype)
+versioned_symbol (libc, __pthread_setcanceltype, pthread_setcanceltype, GLIBC_2_21);
 
-weak_alias (__pthread_setcanceltype, pthread_setcanceltype);
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_12, GLIBC_2_21)
+compat_symbol (libc, __pthread_setcanceltype, pthread_setcanceltype, GLIBC_2_12);
+#endif
index 45f15c264123d78096a7168f8fe9e6d7c110c7d6..9788085b83c29c2c355206e248e0512698bacdf6 100644 (file)
@@ -23,7 +23,6 @@
 
 void __pthread_exit (void *) __attribute__ ((__noreturn__));
 int __pthread_setcancelstate (int, int *);
-int __pthread_setcanceltype (int, int *);
 struct __pthread_cancelation_handler **__pthread_get_cleanup_stack (void);
 int __pthread_once (pthread_once_t *, void (*) (void));
 int __pthread_rwlock_rdlock (pthread_rwlock_t *);
@@ -44,7 +43,6 @@ struct pthread_functions
 {
   void (*ptr___pthread_exit) (void *) __attribute__ ((__noreturn__));
   int (*ptr___pthread_setcancelstate) (int, int *);
-  int (*ptr_pthread_setcanceltype) (int, int *);
   struct __pthread_cancelation_handler **(*ptr___pthread_get_cleanup_stack) (void);
   int (*ptr_pthread_once) (pthread_once_t *, void (*) (void));
   int (*ptr_pthread_rwlock_rdlock) (pthread_rwlock_t *);
index c39c7f117be6680c1a246c655e3da5fca8d4bef4..889a63200dc225cd3c67008c8533fd55dfdcb69c 100644 (file)
@@ -118,6 +118,9 @@ extern int __pthread_cond_clockwait (pthread_cond_t *cond,
 libc_hidden_proto (__pthread_cond_clockwait);
 extern int __pthread_cond_destroy (pthread_cond_t *cond);
 libc_hidden_proto (__pthread_cond_destroy);
+
+extern int __pthread_setcanceltype (int __type, int *__oldtype);
+libc_hidden_proto (__pthread_setcanceltype);
 extern int __pthread_sigmask (int, const sigset_t *, sigset_t *);
 libc_hidden_proto (__pthread_sigmask);
 
index 17656eb119b23d68029d6cb80e2bbdba08f7c58e..c26eddba3dffbea41a06eb1afc3ca0f19f41ac09 100644 (file)
@@ -82,6 +82,7 @@ GLIBC_2.12 pthread_mutexattr_setprotocol F
 GLIBC_2.12 pthread_mutexattr_setpshared F
 GLIBC_2.12 pthread_mutexattr_settype F
 GLIBC_2.12 pthread_self F
+GLIBC_2.12 pthread_setcanceltype F
 GLIBC_2.12 pthread_setschedparam F
 GLIBC_2.12 pthread_sigmask F
 GLIBC_2.13 __fentry__ F
index 0877c0a84bc02082213366e2af911cee4b28d29b..30b598ffd936ba9d55bf134877d3310fa0d9d412 100644 (file)
@@ -57,7 +57,6 @@ GLIBC_2.12 pthread_rwlockattr_getpshared F
 GLIBC_2.12 pthread_rwlockattr_init F
 GLIBC_2.12 pthread_rwlockattr_setpshared F
 GLIBC_2.12 pthread_setcancelstate F
-GLIBC_2.12 pthread_setcanceltype F
 GLIBC_2.12 pthread_setconcurrency F
 GLIBC_2.12 pthread_setschedprio F
 GLIBC_2.12 pthread_setspecific F
index f4cee895808480ca7f03684c79f249f487e58aef..800b7935fbd01b236813d43c42e6e59e0d4b814d 100644 (file)
@@ -79,7 +79,6 @@ GLIBC_2.38 pthread_rwlockattr_getpshared F
 GLIBC_2.38 pthread_rwlockattr_init F
 GLIBC_2.38 pthread_rwlockattr_setpshared F
 GLIBC_2.38 pthread_setcancelstate F
-GLIBC_2.38 pthread_setcanceltype F
 GLIBC_2.38 pthread_setconcurrency F
 GLIBC_2.38 pthread_setschedprio F
 GLIBC_2.38 pthread_setspecific F
This page took 0.114179 seconds and 5 git commands to generate.