diff options
author | Robert Mustacchi <rm@fingolfin.org> | 2020-02-13 18:08:48 +0000 |
---|---|---|
committer | Robert Mustacchi <rm@fingolfin.org> | 2020-02-17 07:29:24 +0000 |
commit | 94494656088303cd79a8b970e5535468c5f0117d (patch) | |
tree | 5d447e6ec3f5b944e91efed8971f66a9956c3a95 | |
parent | c40d33be34d8bd92100aad1cfae8c1aaeee375d6 (diff) | |
download | illumos-joyent-94494656088303cd79a8b970e5535468c5f0117d.tar.gz |
12307 Fix markup errors in mtx(3C)
Reviewed by: Peter Tribble <peter.tribble@gmail.com>
Reviewed by: Jason King <jason.king@joyent.com>
Approved by: Dan McDonald <danmcd@joyent.com>
-rw-r--r-- | usr/src/man/man3c/mtx.3c | 48 |
1 files changed, 25 insertions, 23 deletions
diff --git a/usr/src/man/man3c/mtx.3c b/usr/src/man/man3c/mtx.3c index 677bee08e0..a303adc211 100644 --- a/usr/src/man/man3c/mtx.3c +++ b/usr/src/man/man3c/mtx.3c @@ -11,7 +11,7 @@ .\" .\" Copyright 2016 Joyent, Inc. .\" -.Dd "Jan 11, 2015" +.Dd "February 14, 2020" .Dt MTX 3C .Os .Sh NAME @@ -69,15 +69,15 @@ The following types of mutexes are valid and may be specified by the .Fa type argument: .Bl -tag -width Dv -.It Sy mtx_plain +.It Dv mtx_plain A simple, intra-process mutex. -.It Sy mtx_timed +.It Dv mtx_timed A simple, intra-process mutex, which allows timed locking operations. -.It Sy mtx_plain | mtx_recursive +.It Dv mtx_plain | mtx_recursive An intra-process mutex that may be acquired recursively by the same thread. It must be unlocked an equal number of times that it is locked. -.It Sy mtx_timed | mtx_recursive +.It Dv mtx_timed | mtx_recursive An intra-process mutex that supports timed locking operations and may be acquired recursively by the same thread. It must be unlocked an equal number of times that it is locked. @@ -112,16 +112,16 @@ When they finally return, then they will have obtained the mutex .Fa mtx . .Pp Unless a lock of type -.Sy mtx_recursive +.Dv mtx_recursive was created, a thread calling .Fn mtx_lock when it already holds .Fa mtx will cause the thread to deadlock. -Othewrise, the lock will be successfully taken again. +Otherwise, the lock will be successfully taken again. However, a thread must call .Fn mtx_unlock -for each time that it has acquried +for each time that it has acquired .Fa mtx . .Pp The @@ -135,7 +135,7 @@ if is locked, then it will not block and wait for .Fa mtx and instead return -.Sy thrd_busy +.Dv thrd_busy to indicate that the lock is currently held. .Pp The @@ -149,7 +149,7 @@ The timeout in .Fa ts is treated as an absolute time in UTC to block until, measured based on the -.Sy CLOCK_REALTIME +.Dv CLOCK_REALTIME clock. .Pp The @@ -164,44 +164,46 @@ It is an error to call on a mutex which the calling thread does not currently own. .Sh RETURN VALUES Upon successful completion, the function -.Fn mtx_init returns -.Sy thrd_success. +.Fn mtx_init +returns +.Dv thrd_success . If there was insufficient memory to create the thread, it instead returns -.Sy thrd_nomem . +.Dv thrd_nomem . If any other error occurred, it returns -.Sy thrd_error . +.Dv thrd_error . .Pp The functions .Fn mtx_lock , and .Fn mtx_unlock return -.Sy thrd_success . +.Dv thrd_success . If they were unable to successfully complete the operation, they instead return -.Sy thrd_error . +.Dv thrd_error . .Pp Upon successful completion, the .Fn mtx_timedlock function returns -.Sy thrd_success . +.Dv thrd_success . If the timeout is reached and the calling thread is unable to obtain the mutex, then -.Sy thrd_timedout -is returned . +.Dv thrd_timedout +is returned. If any other error occurs, then -.Sy thrd_error is returned. +.Dv thrd_error +is returned. .Pp Upon successful completion, the .Fn mtx_trylock function returns -.Sy thrd_success . +.Dv thrd_success . If the thread was unable to obtain the mutex because another thread owns it, then it returns -.Sy thrd_busy . +.Dv thrd_busy . Otherwise, an error will have occurred and -.Sy thrd_error +.Dv thrd_error is returned. .Sh INTERFACE STABILITY .Sy Standard |