diff options
author | davidxu <davidxu@FreeBSD.org> | 2010-10-18 05:09:22 +0000 |
---|---|---|
committer | davidxu <davidxu@FreeBSD.org> | 2010-10-18 05:09:22 +0000 |
commit | c6d578b87099319f4889fc41a797c12394855e3c (patch) | |
tree | 5d87e55da61d90b4464bf03c36f9afc2bd9e16aa /lib/libthr/thread/thr_private.h | |
parent | d56bc2d35fc8b6034e0b83b288e1bd50b99722c8 (diff) | |
download | FreeBSD-src-c6d578b87099319f4889fc41a797c12394855e3c.zip FreeBSD-src-c6d578b87099319f4889fc41a797c12394855e3c.tar.gz |
Add pthread_rwlockattr_setkind_np and pthread_rwlockattr_getkind_np, the
functions set or get pthread_rwlock type, current supported types are:
PTHREAD_RWLOCK_PREFER_READER_NP,
PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP,
PTHREAD_RWLOCK_PREFER_WRITER_NP,
default is PTHREAD_RWLOCK_PREFER_WRITER_NONCECURSIVE_NP, this maintains
binary compatible with old code.
Diffstat (limited to 'lib/libthr/thread/thr_private.h')
-rw-r--r-- | lib/libthr/thread/thr_private.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/libthr/thread/thr_private.h b/lib/libthr/thread/thr_private.h index aa9feef..5d0c301 100644 --- a/lib/libthr/thread/thr_private.h +++ b/lib/libthr/thread/thr_private.h @@ -285,11 +285,14 @@ struct pthread_prio { struct pthread_rwlockattr { int pshared; + int kind; }; struct pthread_rwlock { struct urwlock lock; struct pthread *owner; + int recurse; + int kind; }; /* |