diff options
author | davide <davide@FreeBSD.org> | 2013-03-04 12:48:41 +0000 |
---|---|---|
committer | davide <davide@FreeBSD.org> | 2013-03-04 12:48:41 +0000 |
commit | 8374b0e14140d03f8a6128eb532d6ae5f672571b (patch) | |
tree | 1d4d61c131fbdde98f3ffc52c39747ab6e292d2c /sys/sys/mutex.h | |
parent | 7395c58e524e99e35c2ad03ad3dc04b62086b8d9 (diff) | |
download | FreeBSD-src-8374b0e14140d03f8a6128eb532d6ae5f672571b.zip FreeBSD-src-8374b0e14140d03f8a6128eb532d6ae5f672571b.tar.gz |
MFcalloutng:
Introduce sbt variants of msleep(), msleep_spin(), pause(), tsleep() in
the KPI, allowing to specify timeout in 'sbintime_t' rather than ticks.
Sponsored by: Google Summer of Code 2012, iXsystems inc.
Tested by: flo, marius, ian, markj, Fabian Keil
Diffstat (limited to 'sys/sys/mutex.h')
-rw-r--r-- | sys/sys/mutex.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/sys/mutex.h b/sys/sys/mutex.h index 9a36b63..85d6996 100644 --- a/sys/sys/mutex.h +++ b/sys/sys/mutex.h @@ -376,7 +376,8 @@ extern struct mtx_pool *mtxpool_sleep; mtx_assert_((m), (what), __FILE__, __LINE__) #define mtx_sleep(chan, mtx, pri, wmesg, timo) \ - _sleep((chan), &(mtx)->lock_object, (pri), (wmesg), (timo)) + _sleep((chan), &(mtx)->lock_object, (pri), (wmesg), \ + tick_sbt * (timo), 0, C_HARDCLOCK) #define mtx_initialized(m) lock_initalized(&(m)->lock_object) |