Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/share/man/man9 Small markup improvements.



details:   https://anonhg.NetBSD.org/src/rev/a739a19ffff1
branches:  trunk
changeset: 754281:a739a19ffff1
user:      jruoho <jruoho%NetBSD.org@localhost>
date:      Mon Apr 26 07:36:33 2010 +0000

description:
Small markup improvements.

diffstat:

 share/man/man9/uiomove.9 |  68 ++++++++++++++++++++++++++++-------------------
 1 files changed, 40 insertions(+), 28 deletions(-)

diffs (143 lines):

diff -r 6c8085d37102 -r a739a19ffff1 share/man/man9/uiomove.9
--- a/share/man/man9/uiomove.9  Mon Apr 26 04:31:09 2010 +0000
+++ b/share/man/man9/uiomove.9  Mon Apr 26 07:36:33 2010 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: uiomove.9,v 1.15 2010/03/22 18:58:33 joerg Exp $
+.\"    $NetBSD: uiomove.9,v 1.16 2010/04/26 07:36:33 jruoho Exp $
 .\"
 .\" Copyright (c) 1996 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -24,7 +24,7 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd March 7, 2007
+.Dd April 26, 2010
 .Dt UIOMOVE 9
 .Os
 .Sh NAME
@@ -36,7 +36,7 @@
 .Fn uiomove "void *buf" "size_t n" "struct uio *uio"
 .Sh DESCRIPTION
 The
-.Nm
+.Fn uiomove
 function copies up to
 .Fa n
 bytes between the kernel-space address pointed
@@ -49,53 +49,61 @@
 The
 .Fa uio
 argument is a pointer to a
-.Fa struct uio
+.Va struct uio
 as defined by
 .In sys/uio.h :
-.Bd -literal
+.Bd -literal -offset indent
 struct uio {
-       struct  iovec *uio_iov; /* pointer to array of iovecs */
-       int     uio_iovcnt;     /* number of iovecs in array */
-       off_t   uio_offset;     /* offset into file this uio corresponds to */
-       size_t  uio_resid;      /* residual i/o count */
+       struct  iovec *uio_iov;
+       int     uio_iovcnt;
+       off_t   uio_offset;
+       size_t  uio_resid;
        enum    uio_rw uio_rw;
        struct  vmspace *uio_vmspace;
 };
 .Ed
 .Pp
 A
-.Fa struct uio
+.Va struct uio
 typically describes data in motion.
 Several of the fields described below reflect that expectation.
 .Pp
-.Bl -tag -width uio_xxxxxx
-.It uio_iov
+.Bl -tag -width "uio_vmspace "
+.It Va uio_iov
 Pointer to array of
-.Fa struct iovecs :
+.Tn I/O
+vectors to be processed.
+The
+.Va struct iovec
+is defined to be:
 .Bd -literal
 struct iovec {
        void    *iov_base;      /* Base address. */
        size_t   iov_len;       /* Length. */
 };
 .Ed
-.It uio_iovcnt
-The number of iovecs in the array.
-.It uio_offset
+.It Va uio_iovcnt
+The number of
+.Tn I/O
+vectors in the
+.Va uio_iov
+array.
+.It Va uio_offset
 An offset into the corresponding object.
-.It uio_resid
+.It Va uio_resid
 The amount of space described by the structure; notionally, the amount
 of data remaining to be transferred.
-.It uio_rw
+.It Va uio_rw
 A flag indicating whether data should be read into the space
 (UIO_READ) or written from the space (UIO_WRITE).
-.It uio_vmspace
+.It Va uio_vmspace
 A pointer to the address space which is being transferred to or from.
 .El
 .Pp
 The value of
-.Fa uio-\*[Gt]uio_rw
+.Va uio-\*[Gt]uio_rw
 controls whether
-.Nm
+.Fn uiomove
 copies data from
 .Fa buf
 to
@@ -105,24 +113,28 @@
 The lesser of
 .Fa n
 or
-.Fa uio-\*[Gt]uio_resid
+.Va uio-\*[Gt]uio_resid
 bytes are copied.
 .Pp
-.Nm
+.Fn uiomove
 changes fields of the structure pointed to by
 .Fa uio ,
 such that
-.Fa uio-\*[Gt]uio_resid
+.Va uio-\*[Gt]uio_resid
 is decremented by the amount of data moved,
-.Fa uio-\*[Gt]uio_offset
+.Va uio-\*[Gt]uio_offset
 is incremented by the same amount, and the array of iovecs is adjusted
 to point that much farther into the region described.
 This allows multiple calls to
-.Nm
+.Fn uiomove
 to easily be used to fill or drain the region of data.
 .Sh RETURN VALUES
-.Nm
-returns 0 on success or EFAULT if a bad address is encountered.
+Upon successful completion,
+.Fn uiomove
+returns 0.
+If a bad address is encountered,
+.Er EFAULT
+is returned.
 .Sh SEE ALSO
 .Xr copy 9 ,
 .Xr fetch 9 ,



Home | Main Index | Thread Index | Old Index