diff options
| author | Florian Weimer <fweimer@redhat.com> | 2021-05-03 08:12:11 +0200 |
|---|---|---|
| committer | Florian Weimer <fweimer@redhat.com> | 2021-05-03 08:15:53 +0200 |
| commit | 032a9e17a7201765228262b9b6731839dcfdf885 (patch) | |
| tree | 22f8e89d7709cd57c64edb27f065fa10c7c45880 | |
| parent | b7863c732e387032a49b21e9800e1755beaf5e10 (diff) | |
| download | glibc-032a9e17a7201765228262b9b6731839dcfdf885.tar.xz glibc-032a9e17a7201765228262b9b6731839dcfdf885.zip | |
nptl: Move mtx_timedlock into libc
The symbol was moved using scripts/move-symbol-to-libc.py.
The __pthread_mutex_timedlock@@GLIBC_PRIVATE export is no longer
needed, so it is removed with this commit.
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Carlos O'Donell <carlos@redhat.com>
66 files changed, 87 insertions, 43 deletions
diff --git a/nptl/Versions b/nptl/Versions index 43e56068f5..2c729fc605 100644 --- a/nptl/Versions +++ b/nptl/Versions @@ -136,6 +136,7 @@ libc { mtx_destroy; mtx_init; mtx_lock; + mtx_timedlock; thrd_current; thrd_equal; thrd_sleep; @@ -170,6 +171,7 @@ libc { mtx_destroy; mtx_init; mtx_lock; + mtx_timedlock; pthread_cond_clockwait; pthread_condattr_getclock; pthread_condattr_getpshared; @@ -238,7 +240,6 @@ libc { __pthread_getattr_default_np; __pthread_key_delete; __pthread_keys; - __pthread_mutex_timedlock; __pthread_mutex_unlock_usercnt; __pthread_setcancelstate; __pthread_tpp_change_priority; @@ -382,7 +383,6 @@ libpthread { # C11 thread symbols. GLIBC_2.28 { - mtx_timedlock; mtx_trylock; mtx_unlock; thrd_create; diff --git a/nptl/pthread_mutex_timedlock.c b/nptl/pthread_mutex_timedlock.c index b9cc0a24a1..acd78131b2 100644 --- a/nptl/pthread_mutex_timedlock.c +++ b/nptl/pthread_mutex_timedlock.c @@ -632,10 +632,12 @@ ___pthread_mutex_timedlock (pthread_mutex_t *mutex, } #endif /* __TIMESPEC64 != 64 */ versioned_symbol (libc, ___pthread_mutex_timedlock, - __pthread_mutex_timedlock, GLIBC_PRIVATE); -libc_hidden_ver (___pthread_mutex_timedlock, __pthread_mutex_timedlock) -versioned_symbol (libc, ___pthread_mutex_timedlock, pthread_mutex_timedlock, GLIBC_2_34); +libc_hidden_ver (___pthread_mutex_timedlock, __pthread_mutex_timedlock) +#ifndef SHARED +strong_alias (___pthread_mutex_timedlock, __pthread_mutex_timedlock) +#endif + #if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_2, GLIBC_2_34) compat_symbol (libpthread, ___pthread_mutex_timedlock, pthread_mutex_timedlock, GLIBC_2_2); diff --git a/sysdeps/pthread/Makefile b/sysdeps/pthread/Makefile index 10ce314076..73ee8abdca 100644 --- a/sysdeps/pthread/Makefile +++ b/sysdeps/pthread/Makefile @@ -32,7 +32,6 @@ headers += threads.h routines += thrd_current thrd_equal thrd_sleep thrd_yield libpthread-routines += thrd_create thrd_detach thrd_exit thrd_join \ - mtx_timedlock \ mtx_trylock mtx_unlock \ tss_create tss_delete tss_get tss_set @@ -47,6 +46,7 @@ $(libpthread-routines-var) += \ mtx_destroy \ mtx_init \ mtx_lock \ + mtx_timedlock \ tests += tst-cnd-basic tst-mtx-trylock tst-cnd-broadcast \ tst-cnd-timedwait tst-thrd-detach tst-mtx-basic tst-thrd-sleep \ diff --git a/sysdeps/unix/sysv/linux/aarch64/libc.abilist b/sysdeps/unix/sysv/linux/aarch64/libc.abilist index 0c290c1991..a603aef54a 100644 --- a/sysdeps/unix/sysv/linux/aarch64/libc.abilist +++ b/sysdeps/unix/sysv/linux/aarch64/libc.abilist @@ -2209,6 +2209,7 @@ GLIBC_2.28 fcntl64 F GLIBC_2.28 mtx_destroy F GLIBC_2.28 mtx_init F GLIBC_2.28 mtx_lock F +GLIBC_2.28 mtx_timedlock F GLIBC_2.28 renameat2 F GLIBC_2.28 statx F GLIBC_2.28 thrd_current F @@ -2265,6 +2266,7 @@ GLIBC_2.34 cnd_wait F GLIBC_2.34 mtx_destroy F GLIBC_2.34 mtx_init F GLIBC_2.34 mtx_lock F +GLIBC_2.34 mtx_timedlock F GLIBC_2.34 pthread_cond_clockwait F GLIBC_2.34 pthread_condattr_getclock F GLIBC_2.34 pthread_condattr_getpshared F diff --git a/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist b/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist index 37fc95b6ad..384647abf4 100644 --- a/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist +++ b/sysdeps/unix/sysv/linux/aarch64/libpthread.abilist @@ -69,7 +69,6 @@ GLIBC_2.17 sem_unlink F GLIBC_2.17 sem_wait F GLIBC_2.18 pthread_getattr_default_np F GLIBC_2.18 pthread_setattr_default_np F -GLIBC_2.28 mtx_timedlock F GLIBC_2.28 mtx_trylock F GLIBC_2.28 mtx_unlock F GLIBC_2.28 thrd_create F diff --git a/sysdeps/unix/sysv/linux/alpha/libc.abilist b/sysdeps/unix/sysv/linux/alpha/libc.abilist index c940a7a88b..b1ae38e09e 100644 --- a/sysdeps/unix/sysv/linux/alpha/libc.abilist +++ b/sysdeps/unix/sysv/linux/alpha/libc.abilist @@ -2102,6 +2102,7 @@ GLIBC_2.28 fcntl64 F GLIBC_2.28 mtx_destroy F GLIBC_2.28 mtx_init F GLIBC_2.28 mtx_lock F +GLIBC_2.28 mtx_timedlock F GLIBC_2.28 renameat2 F GLIBC_2.28 statx F GLIBC_2.28 thrd_current F @@ -2346,6 +2347,7 @@ GLIBC_2.34 cnd_wait F GLIBC_2.34 mtx_destroy F GLIBC_2.34 mtx_init F GLIBC_2.34 mtx_lock F +GLIBC_2.34 mtx_timedlock F GLIBC_2.34 pthread_cond_clockwait F GLIBC_2.34 pthread_condattr_getclock F GLIBC_2.34 pthread_condattr_getpshared F diff --git a/sysdeps/unix/sysv/linux/alpha/libpthread.abilist b/sysdeps/unix/sysv/linux/alpha/libpthread.abilist index 97c50454fe..03148f24c6 100644 --- a/sysdeps/unix/sysv/linux/alpha/libpthread.abilist +++ b/sysdeps/unix/sysv/linux/alpha/libpthread.abilist @@ -69,7 +69,6 @@ GLIBC_2.2 pthread_yield F GLIBC_2.2 sem_timedwait F GLIBC_2.2.3 __libpthread_version_placeholder F GLIBC_2.2.6 __libpthread_version_placeholder F -GLIBC_2.28 mtx_timedlock F GLIBC_2.28 mtx_trylock F GLIBC_2.28 mtx_unlock F GLIBC_2.28 thrd_create F diff --git a/sysdeps/unix/sysv/linux/arc/libc.abilist b/sysdeps/unix/sysv/linux/arc/libc.abilist index 16e915f68d..797a78d97d 100644 --- a/sysdeps/unix/sysv/linux/arc/libc.abilist +++ |
