about summary refs log tree commit diff
path: root/nptl/pthread_mutex_lock.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2009-07-27 13:43:01 -0700
committerUlrich Drepper <drepper@redhat.com>2009-07-27 13:43:01 -0700
commit052757bfa652d86d7976df430a5272df1f560076 (patch)
tree800e3e7fa826d88a3d21b07b5be39ffee0bcc0c2 /nptl/pthread_mutex_lock.c
parente83c1a8a72b3ea3009e18ecb3fc0778e81655d3b (diff)
downloadglibc-052757bfa652d86d7976df430a5272df1f560076.tar.gz
glibc-052757bfa652d86d7976df430a5272df1f560076.tar.xz
glibc-052757bfa652d86d7976df430a5272df1f560076.zip
Revert "Memory ordering in pthread_mutex_{,timed}lock."
This reverts commit 7b7f43bed134db6a0da34282fffcbf0af10d4613.
Diffstat (limited to 'nptl/pthread_mutex_lock.c')
-rw-r--r--nptl/pthread_mutex_lock.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/nptl/pthread_mutex_lock.c b/nptl/pthread_mutex_lock.c
index a0ff881faf..406e588fdb 100644
--- a/nptl/pthread_mutex_lock.c
+++ b/nptl/pthread_mutex_lock.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002-2007, 2008, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2007, 2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
 
@@ -160,7 +160,7 @@ __pthread_mutex_lock_full (pthread_mutex_t *mutex)
 #endif
 
 	      newval
-		= atomic_compare_and_exchange_val_rel (&mutex->__data.__lock,
+		= atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
 						       newval, oldval);
 
 	      if (newval != oldval)
@@ -285,7 +285,7 @@ __pthread_mutex_lock_full (pthread_mutex_t *mutex)
 #ifdef NO_INCR
 	newval |= FUTEX_WAITERS;
 #endif
-	oldval = atomic_compare_and_exchange_val_rel (&mutex->__data.__lock,
+	oldval = atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
 						      newval, 0);
 
 	if (oldval != 0)
@@ -420,7 +420,7 @@ __pthread_mutex_lock_full (pthread_mutex_t *mutex)
 	    oldprio = ceiling;
 
 	    oldval
-	      = atomic_compare_and_exchange_val_rel (&mutex->__data.__lock,
+	      = atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
 #ifdef NO_INCR
 						     ceilval | 2,
 #else
@@ -434,7 +434,7 @@ __pthread_mutex_lock_full (pthread_mutex_t *mutex)
 	    do
 	      {
 		oldval
-		  = atomic_compare_and_exchange_val_rel (&mutex->__data.__lock,
+		  = atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
 							 ceilval | 2,
 							 ceilval | 1);
 
@@ -445,7 +445,7 @@ __pthread_mutex_lock_full (pthread_mutex_t *mutex)
 		  lll_futex_wait (&mutex->__data.__lock, ceilval | 2,
 				  PTHREAD_MUTEX_PSHARED (mutex));
 	      }
-	    while (atomic_compare_and_exchange_val_rel (&mutex->__data.__lock,
+	    while (atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
 							ceilval | 2, ceilval)
 		   != ceilval);
 	  }