public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/fw/libpthread-20210318b] nptl: Move pthread_setcancelstate into libc
@ 2021-03-18 22:07 Florian Weimer
  0 siblings, 0 replies; only message in thread
From: Florian Weimer @ 2021-03-18 22:07 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=f552b09ae633ce046651b836b0ddb02d2883b5cf

commit f552b09ae633ce046651b836b0ddb02d2883b5cf
Author: Florian Weimer <fweimer@redhat.com>
Date:   Tue Mar 16 18:05:38 2021 +0100

    nptl: Move pthread_setcancelstate into libc
    
    No new symbol version is required because there was a forwarder.
    
    The symbol has been moved using scripts/move-symbol-to-libc.py.
    
    Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>

Diff:
---
 libio/iopopen.c                                       |  5 ++---
 misc/error.c                                          | 19 ++++++-------------
 nptl/Makefile                                         |  2 +-
 nptl/Versions                                         |  2 +-
 nptl/forward.c                                        |  4 ----
 nptl/nptl-init.c                                      |  1 -
 nptl/pthreadP.h                                       |  2 --
 nptl/pthread_setcancelstate.c                         |  6 +++---
 stdlib/fmtmsg.c                                       |  9 ++-------
 sysdeps/nptl/libc-lockP.h                             |  4 +---
 sysdeps/nptl/pthread-functions.h                      |  1 -
 sysdeps/posix/system.c                                |  5 ++---
 sysdeps/unix/sysv/linux/aarch64/libpthread.abilist    |  1 -
 sysdeps/unix/sysv/linux/alpha/libpthread.abilist      |  1 -
 sysdeps/unix/sysv/linux/arc/libpthread.abilist        |  1 -
 sysdeps/unix/sysv/linux/arm/be/libpthread.abilist     |  1 -
 sysdeps/unix/sysv/linux/arm/le/libpthread.abilist     |  1 -
 sysdeps/unix/sysv/linux/csky/libpthread.abilist       |  1 -
 sysdeps/unix/sysv/linux/fatal-prepare.h               |  4 +---
 sysdeps/unix/sysv/linux/hppa/libpthread.abilist       |  1 -
 sysdeps/unix/sysv/linux/i386/libpthread.abilist       |  1 -
 sysdeps/unix/sysv/linux/ia64/libpthread.abilist       |  1 -
 .../unix/sysv/linux/m68k/coldfire/libpthread.abilist  |  1 -
 .../unix/sysv/linux/m68k/m680x0/libpthread.abilist    |  1 -
 .../unix/sysv/linux/microblaze/be/libpthread.abilist  |  1 -
 .../unix/sysv/linux/microblaze/le/libpthread.abilist  |  1 -
 .../unix/sysv/linux/mips/mips32/libpthread.abilist    |  1 -
 .../unix/sysv/linux/mips/mips64/libpthread.abilist    |  1 -
 sysdeps/unix/sysv/linux/nios2/libpthread.abilist      |  1 -
 .../sysv/linux/powerpc/powerpc32/libpthread.abilist   |  1 -
 .../linux/powerpc/powerpc64/be/libpthread.abilist     |  1 -
 .../linux/powerpc/powerpc64/le/libpthread.abilist     |  1 -
 sysdeps/unix/sysv/linux/riscv/rv32/libpthread.abilist |  1 -
 sysdeps/unix/sysv/linux/riscv/rv64/libpthread.abilist |  1 -
 .../unix/sysv/linux/s390/s390-32/libpthread.abilist   |  1 -
 .../unix/sysv/linux/s390/s390-64/libpthread.abilist   |  1 -
 sysdeps/unix/sysv/linux/sh/be/libpthread.abilist      |  1 -
 sysdeps/unix/sysv/linux/sh/le/libpthread.abilist      |  1 -
 .../unix/sysv/linux/sparc/sparc32/libpthread.abilist  |  1 -
 .../unix/sysv/linux/sparc/sparc64/libpthread.abilist  |  1 -
 sysdeps/unix/sysv/linux/spawni.c                      |  5 ++---
 sysdeps/unix/sysv/linux/x86_64/64/libpthread.abilist  |  1 -
 sysdeps/unix/sysv/linux/x86_64/x32/libpthread.abilist |  1 -
 43 files changed, 21 insertions(+), 77 deletions(-)

diff --git a/libio/iopopen.c b/libio/iopopen.c
index 3afca7e173..6b04222c24 100644
--- a/libio/iopopen.c
+++ b/libio/iopopen.c
@@ -282,10 +282,9 @@ _IO_new_proc_close (FILE *fp)
   do
     {
       int state;
-      __libc_ptf_call (__pthread_setcancelstate,
-		       (PTHREAD_CANCEL_DISABLE, &state), 0);
+      __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
       wait_pid = __waitpid (((_IO_proc_file *) fp)->pid, &wstatus, 0);
-      __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
+      __pthread_setcancelstate (state, NULL);
     }
   while (wait_pid == -1 && errno == EINTR);
   if (wait_pid == -1)
diff --git a/misc/error.c b/misc/error.c
index 06cc4a5028..0400c84df8 100644
--- a/misc/error.c
+++ b/misc/error.c
@@ -236,12 +236,11 @@ void
 __error_internal (int status, int errnum, const char *message,
 		  va_list args, unsigned int mode_flags)
 {
-#if defined _LIBC && defined __libc_ptf_call
+#if defined _LIBC
   /* We do not want this call to be cut short by a thread
      cancellation.  Therefore disable cancellation for now.  */
   int state = PTHREAD_CANCEL_ENABLE;
-  __libc_ptf_call (__pthread_setcancelstate,
-		   (PTHREAD_CANCEL_DISABLE, &state), 0);
+  __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
 #endif
 
   flush_stdout ();
@@ -263,9 +262,7 @@ __error_internal (int status, int errnum, const char *message,
 
 #ifdef _LIBC
   _IO_funlockfile (stderr);
-# ifdef __libc_ptf_call
-  __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
-# endif
+  __pthread_setcancelstate (state, NULL);
 #endif
 }
 
@@ -305,13 +302,11 @@ __error_at_line_internal (int status, int errnum, const char *file_name,
       old_line_number = line_number;
     }
 
-#if defined _LIBC && defined __libc_ptf_call
+#if defined _LIBC
   /* We do not want this call to be cut short by a thread
      cancellation.  Therefore disable cancellation for now.  */
   int state = PTHREAD_CANCEL_ENABLE;
-  __libc_ptf_call (__pthread_setcancelstate,
-		   (PTHREAD_CANCEL_DISABLE, &state),
-		   0);
+  __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
 #endif
 
   flush_stdout ();
@@ -341,9 +336,7 @@ __error_at_line_internal (int status, int errnum, const char *file_name,
 
 #ifdef _LIBC
   _IO_funlockfile (stderr);
-# ifdef __libc_ptf_call
-  __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
-# endif
+  __pthread_setcancelstate (state, NULL);
 #endif
 }
 
diff --git a/nptl/Makefile b/nptl/Makefile
index 9485d30ff7..5722832ef6 100644
--- a/nptl/Makefile
+++ b/nptl/Makefile
@@ -82,6 +82,7 @@ routines = \
   pthread_mutex_consistent \
   pthread_once \
   pthread_self \
+  pthread_setcancelstate \
   pthread_setschedparam \
   pthread_sigmask \
   unwind \
@@ -199,7 +200,6 @@ libpthread-routines = \
   pthread_rwlockattr_setpshared \
   pthread_setaffinity \
   pthread_setattr_default_np \
-  pthread_setcancelstate \
   pthread_setcanceltype \
   pthread_setconcurrency \
   pthread_setname \
diff --git a/nptl/Versions b/nptl/Versions
index 9010d99648..5e0affc86b 100644
--- a/nptl/Versions
+++ b/nptl/Versions
@@ -123,6 +123,7 @@ libc {
     __pthread_force_elision;
     __pthread_getattr_default_np;
     __pthread_keys;
+    __pthread_setcancelstate;
     __pthread_unwind;
   }
 }
@@ -180,7 +181,6 @@ libpthread {
     pthread_mutexattr_getkind_np;
     pthread_mutexattr_init;
     pthread_mutexattr_setkind_np;
-    pthread_setcancelstate;
     pthread_setcanceltype;
     pthread_setspecific;
     pthread_sigmask;
diff --git a/nptl/forward.c b/nptl/forward.c
index a4a377ba6a..ef4a17d39b 100644
--- a/nptl/forward.c
+++ b/nptl/forward.c
@@ -102,8 +102,4 @@ FORWARD (pthread_mutex_lock, (pthread_mutex_t *mutex), (mutex), 0)
 
 FORWARD (pthread_mutex_unlock, (pthread_mutex_t *mutex), (mutex), 0)
 
-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)
diff --git a/nptl/nptl-init.c b/nptl/nptl-init.c
index caa06f380a..e7615ffcb6 100644
--- a/nptl/nptl-init.c
+++ b/nptl/nptl-init.c
@@ -85,7 +85,6 @@ static const struct pthread_functions pthread_functions =
     .ptr_pthread_mutex_init = __pthread_mutex_init,
     .ptr_pthread_mutex_lock = __pthread_mutex_lock,
     .ptr_pthread_mutex_unlock = __pthread_mutex_unlock,
-    .ptr___pthread_setcancelstate = __pthread_setcancelstate,
     .ptr_pthread_setcanceltype = __pthread_setcanceltype,
     .ptr___pthread_rwlock_rdlock = __pthread_rwlock_rdlock,
     .ptr___pthread_rwlock_wrlock = __pthread_rwlock_wrlock,
diff --git a/nptl/pthreadP.h b/nptl/pthreadP.h
index 7d88754e67..9f07aa718b 100644
--- a/nptl/pthreadP.h
+++ b/nptl/pthreadP.h
@@ -381,7 +381,6 @@ extern int __pthread_getschedparam (pthread_t thread_id, int *policy,
 				    struct sched_param *param);
 extern int __pthread_setschedparam (pthread_t thread_id, int policy,
 				    const struct sched_param *param);
-extern int __pthread_setcancelstate (int state, int *oldstate);
 extern int __pthread_mutex_init (pthread_mutex_t *__mutex,
 				 const pthread_mutexattr_t *__mutexattr);
 extern int __pthread_mutex_destroy (pthread_mutex_t *__mutex);
@@ -554,7 +553,6 @@ hidden_proto (__pthread_rwlock_unlock)
 hidden_proto (__pthread_key_create)
 hidden_proto (__pthread_getspecific)
 hidden_proto (__pthread_setspecific)
-hidden_proto (__pthread_setcancelstate)
 hidden_proto (__pthread_testcancel)
 hidden_proto (__pthread_mutexattr_init)
 hidden_proto (__pthread_mutexattr_settype)
diff --git a/nptl/pthread_setcancelstate.c b/nptl/pthread_setcancelstate.c
index a0ffbd9338..e3696ca348 100644
--- a/nptl/pthread_setcancelstate.c
+++ b/nptl/pthread_setcancelstate.c
@@ -19,7 +19,7 @@
 #include <errno.h>
 #include "pthreadP.h"
 #include <atomic.h>
-
+#include <libc-lockP.h>
 
 int
 __pthread_setcancelstate (int state, int *oldstate)
@@ -67,5 +67,5 @@ __pthread_setcancelstate (int state, int *oldstate)
 
   return 0;
 }
-strong_alias (__pthread_setcancelstate, pthread_setcancelstate)
-hidden_def (__pthread_setcancelstate)
+libc_hidden_def (__pthread_setcancelstate)
+weak_alias (__pthread_setcancelstate, pthread_setcancelstate)
diff --git a/stdlib/fmtmsg.c b/stdlib/fmtmsg.c
index 2846d34012..428dad07ff 100644
--- a/stdlib/fmtmsg.c
+++ b/stdlib/fmtmsg.c
@@ -122,13 +122,10 @@ fmtmsg (long int classification, const char *label, int severity,
 	return MM_NOTOK;
     }
 
-#ifdef __libc_ptf_call
   /* We do not want this call to be cut short by a thread
      cancellation.  Therefore disable cancellation for now.  */
   int state = PTHREAD_CANCEL_ENABLE;
-  __libc_ptf_call (__pthread_setcancelstate,
-		   (PTHREAD_CANCEL_DISABLE, &state), 0);
-#endif
+  __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
 
   __libc_lock_lock (lock);
 
@@ -197,9 +194,7 @@ fmtmsg (long int classification, const char *label, int severity,
 
   __libc_lock_unlock (lock);
 
-#ifdef __libc_ptf_call
-  __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
-#endif
+  __pthread_setcancelstate (state, NULL);
 
   return result;
 }
diff --git a/sysdeps/nptl/libc-lockP.h b/sysdeps/nptl/libc-lockP.h
index 9550bc37e4..df62ce0e61 100644
--- a/sysdeps/nptl/libc-lockP.h
+++ b/sysdeps/nptl/libc-lockP.h
@@ -341,7 +341,7 @@ extern int __pthread_atfork (void (*__prepare) (void),
 			     void (*__child) (void));
 
 extern int __pthread_setcancelstate (int state, int *oldstate);
-
+libc_hidden_proto (__pthread_setcancelstate)
 
 /* Make the pthread functions weak so that we can elide them from
    single-threaded processes.  */
@@ -367,7 +367,6 @@ weak_extern (__pthread_setspecific)
 weak_extern (__pthread_getspecific)
 weak_extern (__pthread_initialize)
 weak_extern (__pthread_atfork)
-weak_extern (__pthread_setcancelstate)
 # else
 #  pragma weak __pthread_mutex_init
 #  pragma weak __pthread_mutex_destroy
@@ -388,7 +387,6 @@ weak_extern (__pthread_setcancelstate)
 #  pragma weak __pthread_getspecific
 #  pragma weak __pthread_initialize
 #  pragma weak __pthread_atfork
-#  pragma weak __pthread_setcancelstate
 # endif
 #endif
 
diff --git a/sysdeps/nptl/pthread-functions.h b/sysdeps/nptl/pthread-functions.h
index 8f280b9c25..ca7673135d 100644
--- a/sysdeps/nptl/pthread-functions.h
+++ b/sysdeps/nptl/pthread-functions.h
@@ -46,7 +46,6 @@ struct pthread_functions
 				 const pthread_mutexattr_t *);
   int (*ptr_pthread_mutex_lock) (pthread_mutex_t *);
   int (*ptr_pthread_mutex_unlock) (pthread_mutex_t *);
-  int (*ptr___pthread_setcancelstate) (int, int *);
   int (*ptr_pthread_setcanceltype) (int, int *);
   int (*ptr___pthread_rwlock_rdlock) (pthread_rwlock_t *);
   int (*ptr___pthread_rwlock_wrlock) (pthread_rwlock_t *);
diff --git a/sysdeps/posix/system.c b/sysdeps/posix/system.c
index 13c0662f90..48668fb392 100644
--- a/sysdeps/posix/system.c
+++ b/sysdeps/posix/system.c
@@ -82,10 +82,9 @@ cancel_handler (void *arg)
   __kill_noerrno (args->pid, SIGKILL);
 
   int state;
-  __libc_ptf_call (__pthread_setcancelstate,
-                   (PTHREAD_CANCEL_DISABLE, &state), 0);
+  __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
   TEMP_FAILURE_RETRY (__waitpid (args->pid, NULL, 0));
-  __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
+  __pthread_setcancelstate (state, NULL);
 
   DO_LOCK ();
   if (SUB_REF () == 0)
diff --git a/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist b/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist
index 86ab842a47..a622b9722f 100644
--- a/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist
@@ -121,7 +121,6 @@ GLIBC_2.17 pthread_rwlockattr_init F
 GLIBC_2.17 pthread_rwlockattr_setkind_np F
 GLIBC_2.17 pthread_rwlockattr_setpshared F
 GLIBC_2.17 pthread_setaffinity_np F
-GLIBC_2.17 pthread_setcancelstate F
 GLIBC_2.17 pthread_setcanceltype F
 GLIBC_2.17 pthread_setconcurrency F
 GLIBC_2.17 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/alpha/libpthread.abilist b/sysdeps/unix/sysv/linux/alpha/libpthread.abilist
index 7b346a730a..646e5afa46 100644
--- a/sysdeps/unix/sysv/linux/alpha/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/alpha/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/arc/libpthread.abilist b/sysdeps/unix/sysv/linux/arc/libpthread.abilist
index 2b43576dbf..861ed68da6 100644
--- a/sysdeps/unix/sysv/linux/arc/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/arc/libpthread.abilist
@@ -141,7 +141,6 @@ GLIBC_2.32 pthread_rwlockattr_setkind_np F
 GLIBC_2.32 pthread_rwlockattr_setpshared F
 GLIBC_2.32 pthread_setaffinity_np F
 GLIBC_2.32 pthread_setattr_default_np F
-GLIBC_2.32 pthread_setcancelstate F
 GLIBC_2.32 pthread_setcanceltype F
 GLIBC_2.32 pthread_setconcurrency F
 GLIBC_2.32 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/arm/be/libpthread.abilist b/sysdeps/unix/sysv/linux/arm/be/libpthread.abilist
index cb251a68b7..ad8d88e6d1 100644
--- a/sysdeps/unix/sysv/linux/arm/be/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/arm/be/libpthread.abilist
@@ -152,7 +152,6 @@ GLIBC_2.4 pthread_rwlockattr_init F
 GLIBC_2.4 pthread_rwlockattr_setkind_np F
 GLIBC_2.4 pthread_rwlockattr_setpshared F
 GLIBC_2.4 pthread_setaffinity_np F
-GLIBC_2.4 pthread_setcancelstate F
 GLIBC_2.4 pthread_setcanceltype F
 GLIBC_2.4 pthread_setconcurrency F
 GLIBC_2.4 pthread_setschedprio F
diff --git a/sysdeps/unix/sysv/linux/arm/le/libpthread.abilist b/sysdeps/unix/sysv/linux/arm/le/libpthread.abilist
index cb251a68b7..ad8d88e6d1 100644
--- a/sysdeps/unix/sysv/linux/arm/le/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/arm/le/libpthread.abilist
@@ -152,7 +152,6 @@ GLIBC_2.4 pthread_rwlockattr_init F
 GLIBC_2.4 pthread_rwlockattr_setkind_np F
 GLIBC_2.4 pthread_rwlockattr_setpshared F
 GLIBC_2.4 pthread_setaffinity_np F
-GLIBC_2.4 pthread_setcancelstate F
 GLIBC_2.4 pthread_setcanceltype F
 GLIBC_2.4 pthread_setconcurrency F
 GLIBC_2.4 pthread_setschedprio F
diff --git a/sysdeps/unix/sysv/linux/csky/libpthread.abilist b/sysdeps/unix/sysv/linux/csky/libpthread.abilist
index f6f5355a41..fca3d9e9d7 100644
--- a/sysdeps/unix/sysv/linux/csky/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/csky/libpthread.abilist
@@ -136,7 +136,6 @@ GLIBC_2.29 pthread_rwlockattr_setkind_np F
 GLIBC_2.29 pthread_rwlockattr_setpshared F
 GLIBC_2.29 pthread_setaffinity_np F
 GLIBC_2.29 pthread_setattr_default_np F
-GLIBC_2.29 pthread_setcancelstate F
 GLIBC_2.29 pthread_setcanceltype F
 GLIBC_2.29 pthread_setconcurrency F
 GLIBC_2.29 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/fatal-prepare.h b/sysdeps/unix/sysv/linux/fatal-prepare.h
index ec441bdfbc..e2591c5447 100644
--- a/sysdeps/unix/sysv/linux/fatal-prepare.h
+++ b/sysdeps/unix/sysv/linux/fatal-prepare.h
@@ -19,6 +19,4 @@
 
 /* We have to completely disable cancellation.  assert() must not be a
    cancellation point but the implementation uses write() etc.  */
-#define FATAL_PREPARE \
-  __libc_ptf_call (__pthread_setcancelstate, \
-		   (PTHREAD_CANCEL_DISABLE, NULL), 0)
+#define FATAL_PREPARE __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, NULL)
diff --git a/sysdeps/unix/sysv/linux/hppa/libpthread.abilist b/sysdeps/unix/sysv/linux/hppa/libpthread.abilist
index 6b94ef8025..a1e957bff3 100644
--- a/sysdeps/unix/sysv/linux/hppa/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/hppa/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/i386/libpthread.abilist b/sysdeps/unix/sysv/linux/i386/libpthread.abilist
index b95a2615c0..8492b8687d 100644
--- a/sysdeps/unix/sysv/linux/i386/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/i386/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/ia64/libpthread.abilist b/sysdeps/unix/sysv/linux/ia64/libpthread.abilist
index 32a7bca6d4..dc14ff6943 100644
--- a/sysdeps/unix/sysv/linux/ia64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/ia64/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/m68k/coldfire/libpthread.abilist b/sysdeps/unix/sysv/linux/m68k/coldfire/libpthread.abilist
index cb251a68b7..ad8d88e6d1 100644
--- a/sysdeps/unix/sysv/linux/m68k/coldfire/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/m68k/coldfire/libpthread.abilist
@@ -152,7 +152,6 @@ GLIBC_2.4 pthread_rwlockattr_init F
 GLIBC_2.4 pthread_rwlockattr_setkind_np F
 GLIBC_2.4 pthread_rwlockattr_setpshared F
 GLIBC_2.4 pthread_setaffinity_np F
-GLIBC_2.4 pthread_setcancelstate F
 GLIBC_2.4 pthread_setcanceltype F
 GLIBC_2.4 pthread_setconcurrency F
 GLIBC_2.4 pthread_setschedprio F
diff --git a/sysdeps/unix/sysv/linux/m68k/m680x0/libpthread.abilist b/sysdeps/unix/sysv/linux/m68k/m680x0/libpthread.abilist
index b95a2615c0..8492b8687d 100644
--- a/sysdeps/unix/sysv/linux/m68k/m680x0/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/m68k/m680x0/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/microblaze/be/libpthread.abilist b/sysdeps/unix/sysv/linux/microblaze/be/libpthread.abilist
index a5123cf9f0..f94df4ee48 100644
--- a/sysdeps/unix/sysv/linux/microblaze/be/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/microblaze/be/libpthread.abilist
@@ -123,7 +123,6 @@ GLIBC_2.18 pthread_rwlockattr_setkind_np F
 GLIBC_2.18 pthread_rwlockattr_setpshared F
 GLIBC_2.18 pthread_setaffinity_np F
 GLIBC_2.18 pthread_setattr_default_np F
-GLIBC_2.18 pthread_setcancelstate F
 GLIBC_2.18 pthread_setcanceltype F
 GLIBC_2.18 pthread_setconcurrency F
 GLIBC_2.18 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/microblaze/le/libpthread.abilist b/sysdeps/unix/sysv/linux/microblaze/le/libpthread.abilist
index a5123cf9f0..f94df4ee48 100644
--- a/sysdeps/unix/sysv/linux/microblaze/le/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/microblaze/le/libpthread.abilist
@@ -123,7 +123,6 @@ GLIBC_2.18 pthread_rwlockattr_setkind_np F
 GLIBC_2.18 pthread_rwlockattr_setpshared F
 GLIBC_2.18 pthread_setaffinity_np F
 GLIBC_2.18 pthread_setattr_default_np F
-GLIBC_2.18 pthread_setcancelstate F
 GLIBC_2.18 pthread_setcanceltype F
 GLIBC_2.18 pthread_setconcurrency F
 GLIBC_2.18 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/mips/mips32/libpthread.abilist b/sysdeps/unix/sysv/linux/mips/mips32/libpthread.abilist
index ca04c45cfb..c893a3c141 100644
--- a/sysdeps/unix/sysv/linux/mips/mips32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips32/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/libpthread.abilist b/sysdeps/unix/sysv/linux/mips/mips64/libpthread.abilist
index ca04c45cfb..c893a3c141 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips64/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/nios2/libpthread.abilist b/sysdeps/unix/sysv/linux/nios2/libpthread.abilist
index 119ef8737e..d8902e715d 100644
--- a/sysdeps/unix/sysv/linux/nios2/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/nios2/libpthread.abilist
@@ -123,7 +123,6 @@ GLIBC_2.21 pthread_rwlockattr_setkind_np F
 GLIBC_2.21 pthread_rwlockattr_setpshared F
 GLIBC_2.21 pthread_setaffinity_np F
 GLIBC_2.21 pthread_setattr_default_np F
-GLIBC_2.21 pthread_setcancelstate F
 GLIBC_2.21 pthread_setcanceltype F
 GLIBC_2.21 pthread_setconcurrency F
 GLIBC_2.21 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/libpthread.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc32/libpthread.abilist
index c53a224451..250c1baf53 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libpthread.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libpthread.abilist
index 3841622b58..521aa558dc 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libpthread.abilist
@@ -129,7 +129,6 @@ GLIBC_2.3 pthread_rwlockattr_getpshared F
 GLIBC_2.3 pthread_rwlockattr_init F
 GLIBC_2.3 pthread_rwlockattr_setkind_np F
 GLIBC_2.3 pthread_rwlockattr_setpshared F
-GLIBC_2.3 pthread_setcancelstate F
 GLIBC_2.3 pthread_setcanceltype F
 GLIBC_2.3 pthread_setconcurrency F
 GLIBC_2.3 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libpthread.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libpthread.abilist
index 86ab842a47..a622b9722f 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libpthread.abilist
@@ -121,7 +121,6 @@ GLIBC_2.17 pthread_rwlockattr_init F
 GLIBC_2.17 pthread_rwlockattr_setkind_np F
 GLIBC_2.17 pthread_rwlockattr_setpshared F
 GLIBC_2.17 pthread_setaffinity_np F
-GLIBC_2.17 pthread_setcancelstate F
 GLIBC_2.17 pthread_setcanceltype F
 GLIBC_2.17 pthread_setconcurrency F
 GLIBC_2.17 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/riscv/rv32/libpthread.abilist b/sysdeps/unix/sysv/linux/riscv/rv32/libpthread.abilist
index 9d211f5c8e..4bc0280439 100644
--- a/sysdeps/unix/sysv/linux/riscv/rv32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/riscv/rv32/libpthread.abilist
@@ -141,7 +141,6 @@ GLIBC_2.33 pthread_rwlockattr_setkind_np F
 GLIBC_2.33 pthread_rwlockattr_setpshared F
 GLIBC_2.33 pthread_setaffinity_np F
 GLIBC_2.33 pthread_setattr_default_np F
-GLIBC_2.33 pthread_setcancelstate F
 GLIBC_2.33 pthread_setcanceltype F
 GLIBC_2.33 pthread_setconcurrency F
 GLIBC_2.33 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/riscv/rv64/libpthread.abilist b/sysdeps/unix/sysv/linux/riscv/rv64/libpthread.abilist
index 3424758af5..b84202c069 100644
--- a/sysdeps/unix/sysv/linux/riscv/rv64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/riscv/rv64/libpthread.abilist
@@ -123,7 +123,6 @@ GLIBC_2.27 pthread_rwlockattr_setkind_np F
 GLIBC_2.27 pthread_rwlockattr_setpshared F
 GLIBC_2.27 pthread_setaffinity_np F
 GLIBC_2.27 pthread_setattr_default_np F
-GLIBC_2.27 pthread_setcancelstate F
 GLIBC_2.27 pthread_setcanceltype F
 GLIBC_2.27 pthread_setconcurrency F
 GLIBC_2.27 pthread_setname_np F
diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/libpthread.abilist b/sysdeps/unix/sysv/linux/s390/s390-32/libpthread.abilist
index f1a08fa7a2..7033b29d63 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-32/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/libpthread.abilist b/sysdeps/unix/sysv/linux/s390/s390-64/libpthread.abilist
index 698179a47f..b05f1ebb74 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-64/libpthread.abilist
@@ -110,7 +110,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/sh/be/libpthread.abilist b/sysdeps/unix/sysv/linux/sh/be/libpthread.abilist
index 6b94ef8025..a1e957bff3 100644
--- a/sysdeps/unix/sysv/linux/sh/be/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/sh/be/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/sh/le/libpthread.abilist b/sysdeps/unix/sysv/linux/sh/le/libpthread.abilist
index 6b94ef8025..a1e957bff3 100644
--- a/sysdeps/unix/sysv/linux/sh/le/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/sh/le/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/libpthread.abilist b/sysdeps/unix/sysv/linux/sparc/sparc32/libpthread.abilist
index 7b346a730a..646e5afa46 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc32/libpthread.abilist
@@ -46,7 +46,6 @@ GLIBC_2.0 pthread_mutexattr_destroy F
 GLIBC_2.0 pthread_mutexattr_getkind_np F
 GLIBC_2.0 pthread_mutexattr_init F
 GLIBC_2.0 pthread_mutexattr_setkind_np F
-GLIBC_2.0 pthread_setcancelstate F
 GLIBC_2.0 pthread_setcanceltype F
 GLIBC_2.0 pthread_setspecific F
 GLIBC_2.0 pthread_testcancel F
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/libpthread.abilist b/sysdeps/unix/sysv/linux/sparc/sparc64/libpthread.abilist
index 32a7bca6d4..dc14ff6943 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc64/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2 pthread_rwlockattr_getpshared F
 GLIBC_2.2 pthread_rwlockattr_init F
 GLIBC_2.2 pthread_rwlockattr_setkind_np F
 GLIBC_2.2 pthread_rwlockattr_setpshared F
-GLIBC_2.2 pthread_setcancelstate F
 GLIBC_2.2 pthread_setcanceltype F
 GLIBC_2.2 pthread_setconcurrency F
 GLIBC_2.2 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/spawni.c b/sysdeps/unix/sysv/linux/spawni.c
index b53b81b8fc..501f8fbccd 100644
--- a/sysdeps/unix/sysv/linux/spawni.c
+++ b/sysdeps/unix/sysv/linux/spawni.c
@@ -354,8 +354,7 @@ __spawnix (pid_t * pid, const char *file,
 
   /* Disable asynchronous cancellation.  */
   int state;
-  __libc_ptf_call (__pthread_setcancelstate,
-                   (PTHREAD_CANCEL_DISABLE, &state), 0);
+  __pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, &state);
 
   /* Child must set args.err to something non-negative - we rely on
      the parent and child sharing VM.  */
@@ -413,7 +412,7 @@ __spawnix (pid_t * pid, const char *file,
 
   __libc_signal_restore_set (&args.oldmask);
 
-  __libc_ptf_call (__pthread_setcancelstate, (state, NULL), 0);
+  __pthread_setcancelstate (state, NULL);
 
   return ec;
 }
diff --git a/sysdeps/unix/sysv/linux/x86_64/64/libpthread.abilist b/sysdeps/unix/sysv/linux/x86_64/64/libpthread.abilist
index 3097f4375f..69d133c768 100644
--- a/sysdeps/unix/sysv/linux/x86_64/64/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/64/libpthread.abilist
@@ -109,7 +109,6 @@ GLIBC_2.2.5 pthread_rwlockattr_getpshared F
 GLIBC_2.2.5 pthread_rwlockattr_init F
 GLIBC_2.2.5 pthread_rwlockattr_setkind_np F
 GLIBC_2.2.5 pthread_rwlockattr_setpshared F
-GLIBC_2.2.5 pthread_setcancelstate F
 GLIBC_2.2.5 pthread_setcanceltype F
 GLIBC_2.2.5 pthread_setconcurrency F
 GLIBC_2.2.5 pthread_setspecific F
diff --git a/sysdeps/unix/sysv/linux/x86_64/x32/libpthread.abilist b/sysdeps/unix/sysv/linux/x86_64/x32/libpthread.abilist
index f1ae5cb596..d8bea43bd8 100644
--- a/sysdeps/unix/sysv/linux/x86_64/x32/libpthread.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/x32/libpthread.abilist
@@ -121,7 +121,6 @@ GLIBC_2.16 pthread_rwlockattr_init F
 GLIBC_2.16 pthread_rwlockattr_setkind_np F
 GLIBC_2.16 pthread_rwlockattr_setpshared F
 GLIBC_2.16 pthread_setaffinity_np F
-GLIBC_2.16 pthread_setcancelstate F
 GLIBC_2.16 pthread_setcanceltype F
 GLIBC_2.16 pthread_setconcurrency F
 GLIBC_2.16 pthread_setname_np F


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-03-18 22:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-18 22:07 [glibc/fw/libpthread-20210318b] nptl: Move pthread_setcancelstate into libc Florian Weimer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).