From 241ac38c333ae2539182f214dc641d0956f6ff6d Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Fri, 23 Apr 2021 09:47:37 +0200 Subject: nptl: Move pthread_mutexattr_setprotocol into libc The symbol was moved using scripts/move-symbol-to-libc.py. --- nptl/Makefile | 2 +- nptl/Versions | 3 ++- nptl/pthread_mutexattr_setprotocol.c | 11 +++++++++-- 3 files changed, 12 insertions(+), 4 deletions(-) (limited to 'nptl') diff --git a/nptl/Makefile b/nptl/Makefile index 01c383257c..96a01e1c0d 100644 --- a/nptl/Makefile +++ b/nptl/Makefile @@ -111,6 +111,7 @@ routines = \ pthread_mutexattr_gettype \ pthread_mutexattr_init \ pthread_mutexattr_setprioceiling \ + pthread_mutexattr_setprotocol \ pthread_once \ pthread_rwlock_rdlock \ pthread_rwlock_unlock \ @@ -170,7 +171,6 @@ libpthread-routines = \ pthread_getname \ pthread_join \ pthread_join_common \ - pthread_mutexattr_setprotocol \ pthread_mutexattr_setpshared \ pthread_mutexattr_setrobust \ pthread_mutexattr_settype \ diff --git a/nptl/Versions b/nptl/Versions index fde430b622..8dc6d3a4ff 100644 --- a/nptl/Versions +++ b/nptl/Versions @@ -103,6 +103,7 @@ libc { pthread_mutexattr_getprotocol; pthread_mutexattr_getrobust_np; pthread_mutexattr_setprioceiling; + pthread_mutexattr_setprotocol; } GLIBC_2.12 { pthread_mutex_consistent; @@ -154,6 +155,7 @@ libc { pthread_mutexattr_gettype; pthread_mutexattr_init; pthread_mutexattr_setprioceiling; + pthread_mutexattr_setprotocol; pthread_once; pthread_rwlock_rdlock; pthread_rwlock_unlock; @@ -339,7 +341,6 @@ libpthread { } GLIBC_2.4 { - pthread_mutexattr_setprotocol; pthread_mutexattr_setrobust_np; }; diff --git a/nptl/pthread_mutexattr_setprotocol.c b/nptl/pthread_mutexattr_setprotocol.c index 7415ab4e10..9a97729449 100644 --- a/nptl/pthread_mutexattr_setprotocol.c +++ b/nptl/pthread_mutexattr_setprotocol.c @@ -19,10 +19,10 @@ #include #include - +#include int -pthread_mutexattr_setprotocol (pthread_mutexattr_t *attr, int protocol) +__pthread_mutexattr_setprotocol (pthread_mutexattr_t *attr, int protocol) { if (protocol != PTHREAD_PRIO_NONE && protocol != PTHREAD_PRIO_INHERIT @@ -36,3 +36,10 @@ pthread_mutexattr_setprotocol (pthread_mutexattr_t *attr, int protocol) return 0; } +versioned_symbol (libc, __pthread_mutexattr_setprotocol, + pthread_mutexattr_setprotocol, GLIBC_2_34); + +#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_4, GLIBC_2_34) +compat_symbol (libpthread, __pthread_mutexattr_setprotocol, + pthread_mutexattr_setprotocol, GLIBC_2_4); +#endif -- cgit v1.2.3