aboutsummaryrefslogtreecommitdiff
path: root/nptl/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-12-08 03:13:06 +0000
committerUlrich Drepper <drepper@redhat.com>2002-12-08 03:13:06 +0000
commit09efc3ba1269f79b78ee0724501fc762c2d5ab49 (patch)
tree840ca5c526b221f3510f23b1f17c9e379b84129f /nptl/sysdeps
parent6ccb3834ebf1cb65d180144442a68cd1c24f1dd5 (diff)
downloadglibc-09efc3ba1269f79b78ee0724501fc762c2d5ab49.tar
glibc-09efc3ba1269f79b78ee0724501fc762c2d5ab49.tar.gz
glibc-09efc3ba1269f79b78ee0724501fc762c2d5ab49.tar.bz2
glibc-09efc3ba1269f79b78ee0724501fc762c2d5ab49.zip
Update.
2002-12-07 Ulrich Drepper <drepper@redhat.com> * sysdeps/generic/bits/stdio-lock.h (_IO_lock_trylock): New define.
Diffstat (limited to 'nptl/sysdeps')
-rw-r--r--nptl/sysdeps/pthread/bits/libc-lock.h9
-rw-r--r--nptl/sysdeps/unix/sysv/linux/i386/pthread_once.S3
-rw-r--r--nptl/sysdeps/unix/sysv/linux/pthread_kill.c3
3 files changed, 10 insertions, 5 deletions
diff --git a/nptl/sysdeps/pthread/bits/libc-lock.h b/nptl/sysdeps/pthread/bits/libc-lock.h
index 30e3410cbc..cb2154956b 100644
--- a/nptl/sysdeps/pthread/bits/libc-lock.h
+++ b/nptl/sysdeps/pthread/bits/libc-lock.h
@@ -1,4 +1,4 @@
-/* libc-internal interface for mutex locks. LinuxThreads version.
+/* libc-internal interface for mutex locks. NPTL version.
Copyright (C) 1996-2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -254,8 +254,8 @@ typedef pthread_key_t __libc_key_t;
/* Try to lock the recursive named lock variable. */
#if defined _LIBC && (!defined NOT_IN_libc || defined IS_IN_libpthread)
-# define __libc_lock_trylock_recursive(NAME) \
- do { \
+# define __libc_lock_trylock_recursive(NAME) \
+ ({ \
int result = 0; \
void *self = THREAD_SELF; \
if ((NAME).owner != self) \
@@ -270,7 +270,8 @@ typedef pthread_key_t __libc_key_t;
} \
else \
++(NAME).cnt; \
- } while (0)
+ result; \
+ })
#else
# define __libc_lock_trylock_recursive(NAME) \
__libc_maybe_call (__pthread_mutex_trylock, (&(NAME)), 0)
diff --git a/nptl/sysdeps/unix/sysv/linux/i386/pthread_once.S b/nptl/sysdeps/unix/sysv/linux/i386/pthread_once.S
index 747c8ec2d2..931e38bac3 100644
--- a/nptl/sysdeps/unix/sysv/linux/i386/pthread_once.S
+++ b/nptl/sysdeps/unix/sysv/linux/i386/pthread_once.S
@@ -134,6 +134,9 @@ __pthread_once:
.size __pthread_once,.-__pthread_once
+ .globl __pthread_once_internal
+__pthread_once_internal = __pthread_once
+
.globl pthread_once
pthread_once = __pthread_once
diff --git a/nptl/sysdeps/unix/sysv/linux/pthread_kill.c b/nptl/sysdeps/unix/sysv/linux/pthread_kill.c
index f5c2377e7e..2c31dd667a 100644
--- a/nptl/sysdeps/unix/sysv/linux/pthread_kill.c
+++ b/nptl/sysdeps/unix/sysv/linux/pthread_kill.c
@@ -25,7 +25,7 @@
int
-pthread_kill (threadid, signo)
+__pthread_kill (threadid, signo)
pthread_t threadid;
int signo;
{
@@ -34,3 +34,4 @@ pthread_kill (threadid, signo)
/* We have a special syscall to do the work. */
return INLINE_SYSCALL (tkill, 2, pd->tid, signo);
}
+strong_alias (__pthread_kill, pthread_kill)