aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Kerrisk <mtk.manpages@gmail.com>2016-04-18 14:53:11 +0100
committerMichael Kerrisk <mtk.manpages@gmail.com>2016-04-18 14:57:33 +0100
commit3b31ec64ab32a2b5d90f0e845d850bdd12c97673 (patch)
tree73d9ff52abfed44e303b731ac1d5c5cea92e70b3
parentd948a870547fb048f9c42c8e1de3f81b2927bdc8 (diff)
downloadman-pages-3b31ec64ab32a2b5d90f0e845d850bdd12c97673.tar.gz
readv.2: Tweaks to Christoph's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
-rw-r--r--man2/readv.255
1 files changed, 31 insertions, 24 deletions
diff --git a/man2/readv.2 b/man2/readv.2
index 6da95caefb..c533f0e7cc 100644
--- a/man2/readv.2
+++ b/man2/readv.2
@@ -186,38 +186,41 @@ The file referred to by
must be capable of seeking.
.SS preadv2() and pwritev2()
-This pair of system calls has similar functionality to the
+These system calls are similar to
.BR preadv ()
and
.BR pwritev ()
-calls, but adds a fifth argument, \fIflags\fP, which modifies the behavior on a per call basis.
+calls, but add a fifth argument,
+.IR flags ,
+which modifies the behavior on a per-call basis.
-Like the
+Unlike
.BR preadv ()
and
-.BR pwritev ()
-calls, they accept an \fIoffset\fP argument. Unlike those calls, if the \fIoffset\fP argument is set to -1 then the current file offset is used and updated.
+.BR pwritev (),
+if the
+.I offset
+argument is \-1, then the current file offset is used and updated.
-The \fIflags\fP arguments to
-.BR preadv2 ()
-and
-.BR pwritev2 ()
-contains a bitwise OR of one or more of the following flags:
+The
+.I flags
+argument contains a bitwise OR of zero or more of the following flags:
.TP
.BR RWF_HIPRI " (since Linux 4.6)"
-High priority read/write. Allows block based filesystems to use polling of the
-device, which provides lower latency, but may use additional ressources. (Currently
-only usable on a file descriptor opened using the
-.BR O_DIRECT " flag)."
-
+High priority read/write.
+Allows block-based filesystems to use polling of the device,
+which provides lower latency, but may use additional resources.
+(Currently, this feature is usable only on a file descriptor opened using the
+.BR O_DIRECT
+flag.)
.SH RETURN VALUE
On success,
-.BR readv () ","
+.BR readv (),
.BR preadv ()
and
.BR preadv2 ()
return the number of bytes read;
-.BR writev () ","
+.BR writev (),
.BR pwritev ()
and
.BR pwritev2 ()
@@ -236,9 +239,9 @@ The errors are as given for
and
.BR write (2).
Furthermore,
-.BR preadv () ","
-.BR preadv2 () ","
-.BR pwritev ()
+.BR preadv (),
+.BR preadv2 (),
+.BR pwritev (),
and
.BR pwritev2 ()
can also fail for the same reasons as
@@ -253,14 +256,18 @@ values overflows an
value.
.TP
.B EINVAL
-The vector count \fIiovcnt\fP is less than zero or greater than the
-permitted maximum. Or, an unknown flag is specified in \fIflags\fP.
+The vector count,
+.IR iovcnt ,
+is less than zero or greater than the permitted maximum.
+.TP
+.B EINVAL
+An unknown flag is specified in \fIflags\fP.
.SH VERSIONS
.BR preadv ()
and
.BR pwritev ()
first appeared in Linux 2.6.30; library support was added in glibc 2.10.
-.sp
+
.BR preadv2 ()
and
.BR pwritev2 ()
@@ -281,7 +288,7 @@ nonstandard, but present also on the modern BSDs.
.sp
.BR preadv2 (),
.BR pwritev2 ():
-nonstandard, Linux extension.
+nonstandard Linux extension.
.SH NOTES
POSIX.1 allows an implementation to place a limit on
the number of items that can be passed in