summaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2001-08-23 23:52:59 +0000
committerjhb <jhb@FreeBSD.org>2001-08-23 23:52:59 +0000
commit7b5df6201459884d5b8576f925514663141fee79 (patch)
treee2943d7720c571c9e9d8b6c8081b49b564c5814d /share
parent46cf5c221ae24cf7f4edbbddaff46d722f4559b0 (diff)
downloadFreeBSD-src-7b5df6201459884d5b8576f925514663141fee79.zip
FreeBSD-src-7b5df6201459884d5b8576f925514663141fee79.tar.gz
- callout_stop() now returns an integer value instead of void so
describe it. - Add a return values section.
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/timeout.917
1 files changed, 16 insertions, 1 deletions
diff --git a/share/man/man9/timeout.9 b/share/man/man9/timeout.9
index 965b719..fbf89f0 100644
--- a/share/man/man9/timeout.9
+++ b/share/man/man9/timeout.9
@@ -66,7 +66,7 @@ struct callout_handle handle = CALLOUT_HANDLE_INITIALIZER(&handle)
.Fn untimeout "timeout_t *func" "void *arg" "struct callout_handle handle"
.Ft void
.Fn callout_init "struct callout *c" "int mpsafe"
-.Ft void
+.Ft int
.Fn callout_stop "struct callout *c"
.Ft void
.Fn callout_reset "struct callout *c" "int ticks" "timeout_t *func" "void *arg"
@@ -181,6 +181,11 @@ and released when the callout function returns.
The function
.Fn callout_stop
cancels a callout if it is currently pending.
+If the callout is pending, then
+.Fn callout_stop
+will return a non-zero value.
+If the callout has already been serviced or is currently being serviced,
+then zero will be returned.
.Pp
The function
.Fn callout_reset
@@ -189,6 +194,16 @@ first calls
to disestablish the callout, and then establishes a new callout in the
same manner as
.Fn timeout .
+.Sh RETURN VALUES
+The
+.Fn timeout
+function returns a
+.Ft struct callout_handle
+that can be passed to
+.Fn untimeout .
+The
+.Fn callout_stop
+function returns non-zero if the callout is still pending or zero otherwise.
.Sh HISTORY
The current timeout and untimeout routines are based on the work of
.An Adam M. Costello
OpenPOWER on IntegriCloud