Clarify usage of aio(4) with kqueue(2)
Reviewed by: jhb MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D11299
This commit is contained in:
parent
514fd0b8d3
commit
09986d3bd2
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=320255
@ -24,7 +24,7 @@
|
||||
.\"
|
||||
.\" $FreeBSD$
|
||||
.\"
|
||||
.Dd June 17, 2017
|
||||
.Dd June 22, 2017
|
||||
.Dt KQUEUE 2
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -351,33 +351,18 @@ case.
|
||||
Takes a descriptor as the identifier, and returns whenever
|
||||
there is no remaining data in the write buffer.
|
||||
.It Dv EVFILT_AIO
|
||||
The sigevent portion of the AIO request is filled in, with
|
||||
.Va sigev_notify_kqueue
|
||||
containing the descriptor of the kqueue that the event should
|
||||
be attached to,
|
||||
.Va sigev_notify_kevent_flags
|
||||
containing the kevent flags which should be
|
||||
.Dv EV_ONESHOT ,
|
||||
.Dv EV_CLEAR
|
||||
or
|
||||
.Dv EV_DISPATCH ,
|
||||
.Va sigev_value
|
||||
containing the udata value, and
|
||||
.Va sigev_notify
|
||||
set to
|
||||
.Dv SIGEV_KEVENT .
|
||||
When the
|
||||
.Fn aio_*
|
||||
system call is made, the event will be registered
|
||||
with the specified kqueue, and the
|
||||
.Va ident
|
||||
argument set to the
|
||||
.Fa struct aiocb
|
||||
returned by the
|
||||
.Fn aio_*
|
||||
system call.
|
||||
Events for this filter are not registered with
|
||||
.Fn kevent
|
||||
directly but are registered via the
|
||||
.Va aio_sigevent
|
||||
member of an asychronous I/O request when it is scheduled via an asychronous I/O
|
||||
system call such as
|
||||
.Fn aio_read .
|
||||
The filter returns under the same conditions as
|
||||
.Fn aio_error .
|
||||
For more details on this filter see
|
||||
.Xr sigevent 3 and
|
||||
.Xr aio 4 .
|
||||
.It Dv EVFILT_VNODE
|
||||
Takes a file descriptor as the identifier and the events to watch for in
|
||||
.Va fflags ,
|
||||
|
@ -27,7 +27,7 @@
|
||||
.\"
|
||||
.\" $FreeBSD$
|
||||
.\"
|
||||
.Dd July 21, 2016
|
||||
.Dd June 22, 2017
|
||||
.Dt AIO 4
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -161,11 +161,27 @@ field which can be used to request notification when an operation completes.
|
||||
For
|
||||
.Dv SIGEV_KEVENT
|
||||
notifications,
|
||||
the posted kevent will contain:
|
||||
the
|
||||
.Va sigevent
|
||||
.Ap
|
||||
s
|
||||
.Va sigev_notify_kqueue
|
||||
field should contain the descriptor of the kqueue that the event should be attached
|
||||
to, its
|
||||
.Va sigev_notify_kevent_flags
|
||||
field may contain
|
||||
.Dv EV_ONESHOT ,
|
||||
.Dv EV_CLEAR , and/or
|
||||
.Dv EV_DISPATCH , and its
|
||||
.Va sigev_notify
|
||||
field should be set to
|
||||
.Dv SIGEV_KEVENT .
|
||||
The posted kevent will contain:
|
||||
.Bl -column ".Va filter"
|
||||
.It Sy Member Ta Sy Value
|
||||
.It Va ident Ta asynchronous I/O control buffer pointer
|
||||
.It Va filter Ta Dv EVFILT_AIO
|
||||
.It Va flags Ta Dv EV_EOF
|
||||
.It Va udata Ta
|
||||
value stored in
|
||||
.Va aio_sigevent.sigev_value
|
||||
|
Loading…
Reference in New Issue
Block a user