From owner-svn-src-all@freebsd.org Mon Jul 31 22:36:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CFE67DBF585; Mon, 31 Jul 2017 22:36:04 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ABB786C333; Mon, 31 Jul 2017 22:36:04 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v6VMa38g077123; Mon, 31 Jul 2017 22:36:03 GMT (envelope-from asomers@FreeBSD.org) Received: (from asomers@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v6VMa31R077121; Mon, 31 Jul 2017 22:36:03 GMT (envelope-from asomers@FreeBSD.org) Message-Id: <201707312236.v6VMa31R077121@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: asomers set sender to asomers@FreeBSD.org using -f From: Alan Somers Date: Mon, 31 Jul 2017 22:36:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r321829 - in stable/10: lib/libc/sys share/man/man4 X-SVN-Group: stable-10 X-SVN-Commit-Author: asomers X-SVN-Commit-Paths: in stable/10: lib/libc/sys share/man/man4 X-SVN-Commit-Revision: 321829 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Jul 2017 22:36:04 -0000 Author: asomers Date: Mon Jul 31 22:36:03 2017 New Revision: 321829 URL: https://svnweb.freebsd.org/changeset/base/321829 Log: Clarify usage of aio(4) with kqueue(2) Reviewed by: jhb MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D11299 Modified: stable/10/lib/libc/sys/kqueue.2 stable/10/share/man/man4/aio.4 Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libc/sys/kqueue.2 ============================================================================== --- stable/10/lib/libc/sys/kqueue.2 Mon Jul 31 22:32:11 2017 (r321828) +++ stable/10/lib/libc/sys/kqueue.2 Mon Jul 31 22:36:03 2017 (r321829) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 3, 2016 +.Dd June 22, 2017 .Dt KQUEUE 2 .Os .Sh NAME @@ -327,33 +327,18 @@ identical to the .Dv EVFILT_READ case. .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 , Modified: stable/10/share/man/man4/aio.4 ============================================================================== --- stable/10/share/man/man4/aio.4 Mon Jul 31 22:32:11 2017 (r321828) +++ stable/10/share/man/man4/aio.4 Mon Jul 31 22:36:03 2017 (r321829) @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 15, 2016 +.Dd June 22, 2017 .Dt AIO 4 .Os .Sh NAME @@ -59,11 +59,27 @@ field which can be used to request notification when a 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