summaryrefslogtreecommitdiff
path: root/libpthread/sysdeps/generic/bits/mutex.h
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2010-08-01 01:06:13 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2010-08-01 01:06:13 +0200
commit8a42f9a3ff374eab8dec61b1d4eb8567a2a91ade (patch)
treeef4b3d43559f4f6455f70ef04fc853a05d3ff823 /libpthread/sysdeps/generic/bits/mutex.h
parent68567b88ee8f9e395e0c1f0a565affe8a1d4d68b (diff)
parent90dd2d73435a8e1bbcccf5ed99a91b2c438557f4 (diff)
Merge branch 'libpthread' into libpthread-moved
Diffstat (limited to 'libpthread/sysdeps/generic/bits/mutex.h')
-rw-r--r--libpthread/sysdeps/generic/bits/mutex.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/libpthread/sysdeps/generic/bits/mutex.h b/libpthread/sysdeps/generic/bits/mutex.h
index 86068cf5..c734c393 100644
--- a/libpthread/sysdeps/generic/bits/mutex.h
+++ b/libpthread/sysdeps/generic/bits/mutex.h
@@ -57,9 +57,17 @@ struct __pthread_mutex
# define __PTHREAD_MUTEX_INITIALIZER \
{ __PTHREAD_SPIN_LOCK_INITIALIZER, __PTHREAD_SPIN_LOCK_INITIALIZER, 0, 0, 0, 0, 0, 0 }
+# define __PTHREAD_ERRORCHECK_MUTEXATTR ((struct __pthread_mutexattr *) ((unsigned long) __PTHREAD_MUTEX_ERRORCHECK + 1))
+
+# define __PTHREAD_ERRORCHECK_MUTEX_INITIALIZER \
+ { __PTHREAD_SPIN_LOCK_INITIALIZER, __PTHREAD_SPIN_LOCK_INITIALIZER, 0, 0, \
+ __PTHREAD_ERRORCHECK_MUTEXATTR, 0, 0, 0 }
+
+# define __PTHREAD_RECURSIVE_MUTEXATTR ((struct __pthread_mutexattr *) ((unsigned long) __PTHREAD_MUTEX_RECURSIVE + 1))
+
# define __PTHREAD_RECURSIVE_MUTEX_INITIALIZER \
{ __PTHREAD_SPIN_LOCK_INITIALIZER, __PTHREAD_SPIN_LOCK_INITIALIZER, 0, 0, \
- (struct __pthread_mutexattr *) &__pthread_recursive_mutexattr, 0, 0, 0 }
+ __PTHREAD_RECURSIVE_MUTEXATTR, 0, 0, 0 }
# endif
#endif /* Not __pthread_mutex_defined. */