summaryrefslogtreecommitdiffstats
path: root/lib/libthr
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2006-12-05 06:53:44 +0000
committerdavidxu <davidxu@FreeBSD.org>2006-12-05 06:53:44 +0000
commitf1f529336506971061548ea5dd335e3874fad4ca (patch)
treeb1f5f6378f2ccdffaaf489927cfd74df0eddb876 /lib/libthr
parentec5c7a4e2d98ea8bf431990ca781afc1ddfd7a2f (diff)
downloadFreeBSD-src-f1f529336506971061548ea5dd335e3874fad4ca.zip
FreeBSD-src-f1f529336506971061548ea5dd335e3874fad4ca.tar.gz
Add _thr_ucond_init().
Diffstat (limited to 'lib/libthr')
-rw-r--r--lib/libthr/thread/thr_umtx.c6
-rw-r--r--lib/libthr/thread/thr_umtx.h7
2 files changed, 10 insertions, 3 deletions
diff --git a/lib/libthr/thread/thr_umtx.c b/lib/libthr/thread/thr_umtx.c
index 7529c85..8a8c908 100644
--- a/lib/libthr/thread/thr_umtx.c
+++ b/lib/libthr/thread/thr_umtx.c
@@ -105,6 +105,12 @@ _thr_umtx_wake(volatile umtx_t *mtx, int nr_wakeup)
return (errno);
}
+void
+_thr_ucond_init(struct ucond *cv)
+{
+ bzero(cv, sizeof(struct ucond));
+}
+
int
_thr_ucond_wait(struct ucond *cv, struct umutex *m,
const struct timespec *timeout, int check_unparking)
diff --git a/lib/libthr/thread/thr_umtx.h b/lib/libthr/thread/thr_umtx.h
index 135672b..a0f331a 100644
--- a/lib/libthr/thread/thr_umtx.h
+++ b/lib/libthr/thread/thr_umtx.h
@@ -49,9 +49,10 @@ int _thr_umtx_wait(volatile umtx_t *mtx, umtx_t exp,
const struct timespec *timeout) __hidden;
int _thr_umtx_wake(volatile umtx_t *mtx, int count) __hidden;
int _thr_ucond_wait(struct ucond *cv, struct umutex *m,
- const struct timespec *timeout, int check_unpaking);
-int _thr_ucond_signal(struct ucond *cv);
-int _thr_ucond_broadcast(struct ucond *cv);
+ const struct timespec *timeout, int check_unpaking) __hidden;
+void _thr_ucond_init(struct ucond *cv) __hidden;
+int _thr_ucond_signal(struct ucond *cv) __hidden;
+int _thr_ucond_broadcast(struct ucond *cv) __hidden;
static inline int
_thr_umutex_trylock(struct umutex *mtx, uint32_t id)
OpenPOWER on IntegriCloud