summaryrefslogtreecommitdiff
path: root/share/man/man9
diff options
context:
space:
mode:
authorDavid Gwynne <dlg@cvs.openbsd.org>2015-01-27 10:18:32 +0000
committerDavid Gwynne <dlg@cvs.openbsd.org>2015-01-27 10:18:32 +0000
commit99e0281480ac2615eeb32cbf90c4f6df87ed3b79 (patch)
tree2968cf6685022fc137297c9e692850503a3db3df /share/man/man9
parenta498146ed2c8d88ac8cc85e6cf0aa02a00603c31 (diff)
remove workq code. its been replaced with tasks.
it has been unused since december, and unhooked from the build since christmas. ok krw@
Diffstat (limited to 'share/man/man9')
-rw-r--r--share/man/man9/workq_add_task.9138
1 files changed, 0 insertions, 138 deletions
diff --git a/share/man/man9/workq_add_task.9 b/share/man/man9/workq_add_task.9
deleted file mode 100644
index ca978044bf9..00000000000
--- a/share/man/man9/workq_add_task.9
+++ /dev/null
@@ -1,138 +0,0 @@
-.\" $OpenBSD: workq_add_task.9,v 1.17 2014/01/21 03:15:46 schwarze Exp $
-.\"
-.\" Copyright (c) 2007 David Gwynne <dlg@openbsd.org>
-.\"
-.\" Permission to use, copy, modify, and distribute this software for any
-.\" purpose with or without fee is hereby granted, provided that the above
-.\" copyright notice and this permission notice appear in all copies.
-.\"
-.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
-.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
-.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
-.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-.\"
-.Dd $Mdocdate: January 21 2014 $
-.Dt WORKQ_ADD_TASK 9
-.Os
-.Sh NAME
-.Nm workq_add_task ,
-.Nm workq_queue_task ,
-.Nm workq_create ,
-.Nm workq_destroy
-.Nd work queues
-.Sh SYNOPSIS
-.In sys/workq.h
-.Ft int
-.Fn "workq_add_task" "struct workq *wq" "int flags" "void (*func)(void *, void *)" "void *arg1" "void *arg2"
-.Ft void
-.Fn "workq_queue_task" "struct workq *wq" "struct workq_task *wqt" "int flags" "void (*func)(void *, void *)" "void *arg1" "void *arg2"
-.Ft struct workq *
-.Fn "workq_create" "const char *name" "int maxthreads" "int ipl"
-.Ft void
-.Fn "workq_destroy" "struct workq *wq"
-.Sh DESCRIPTION
-The
-workq
-framework API provides a mechanism to defer tasks to a process context when
-it is impossible to run such a task in the current context.
-.Pp
-.Fn workq_add_task
-adds a task to the workq specified by the
-.Fa wq
-argument.
-If
-.Fa wq
-is
-.Dv NULL
-the task will be run by the kernel's generic work queue.
-Tasks in the kernel's generic work queue should not run for long periods of
-time, they should use their own workq for task processing.
-A task is specified by the
-.Fa func
-argument, and will be called with
-.Fa arg1
-and
-.Fa arg2 .
-Two arguments are allowed to provide additional flexibility to the called
-function.
-In many cases, one may wish to perform an action on a target.
-Two arguments allow both target and action to be passed without
-the need for a wrapper struct to contain them in a single argument.
-The
-.Fa flags
-argument specifies creation and runtime characteristics of the task.
-The possible flags are:
-.Pp
-.Bl -tag -offset indent -width WQ_WAITOKXXX -compact
-.It Dv WQ_WAITOK
-Wait for resources to become available.
-If resources are not available and this flag is not set then
-.Fn workq_add_task
-will return
-.Dv ENOMEM .
-.El
-.Pp
-.Fn workq_queue_task
-adds a task to the workq specified by the
-.Fa wq
-argument, using the memory provided by the
-.Fa wqt
-argument to store that task's entry on the workq.
-The
-.Fa flags ,
-.Fa func ,
-.Fa arg1 ,
-and
-.Fa arg2
-arguments are the same as those in the
-.Fn workq_add_task
-function.
-However, because the caller is responsible for providing the memory
-needed to store the task on the workq,
-.Fn workq_queue_task
-is guaranteed to succeed.
-.Pp
-.Fn workq_create
-creates a workq to be used when tasks would unnecessarily block the kernel
-workq.
-The
-.Fa name
-argument specifies the name of the kernel threads that run the tasks.
-.Fa maxthreads
-specifies the maximum number of worker threads that will service the work
-queue.
-.Fa ipl
-specifies the interrupt protection level at which the workq can be safely used.
-See
-.Xr spl 9
-for a list of the IPLs.
-.Pp
-.Fn workq_destroy
-causes the resources associated with a previously created workq to be freed.
-It will wait till all the tasks in the work queue are completed before
-returning.
-.Pp
-.Fn workq_add_task ,
-.Fn workq_create ,
-and
-.Fn workq_destroy
-can be called during
-.Xr autoconf 9
-or from process context.
-.Fn workq_add_task
-can additionally be called from interrupt context if
-.Dv WQ_WAITOK
-is not specified.
-.Sh SEE ALSO
-.Xr autoconf 9 ,
-.Xr spl 9
-.Sh HISTORY
-The workq framework was originally written by
-.An Ted Unangst Aq Mt tedu@openbsd.org ,
-and heavily influenced by arguments with
-.An David Gwynne Aq Mt dlg@openbsd.org .
-The workq framework first appeared in
-.Ox 4.2 .