mirror of https://github.com/mkerrisk/man-pages
process_madvise.2: Restructure the text in DESCRIPTION a little
The 'advice' subsection fell in the middle of other text in the DESCRIPTION, which is a little confusing. Instead, move that subsection to the end of the DESCRIPTION, and make some other minor text reorganization so that related details are placed in the same paragraphs. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
e3ce016472
commit
3aac0708a9
|
@ -83,10 +83,50 @@ The
|
|||
specifies the number of elements in the
|
||||
.I iovec
|
||||
structure.
|
||||
This value must be less than or equal to
|
||||
.BR IOV_MAX
|
||||
(defined in
|
||||
.I <limits.h>
|
||||
or accessible via the call
|
||||
.IR sysconf(_SC_IOV_MAX) ).
|
||||
.PP
|
||||
The
|
||||
.I advice
|
||||
argument is one of the values listed below.
|
||||
.PP
|
||||
The
|
||||
.I flags
|
||||
argument is reserved for future use; currently, this argument must be
|
||||
specified as 0.
|
||||
.PP
|
||||
The
|
||||
.I vlen
|
||||
and
|
||||
.I iovec
|
||||
arguments are checked before applying any hints.
|
||||
If the
|
||||
.I vlen
|
||||
is too big, or
|
||||
.I iovec
|
||||
is invalid,
|
||||
then an error will be returned immediately and no advice will be applied.
|
||||
.PP
|
||||
The hint might be applied to a part of
|
||||
.I iovec
|
||||
if one of its elements points to an invalid memory region in the
|
||||
remote process.
|
||||
No further elements will be processed beyond that point.
|
||||
.PP
|
||||
Permission to provide a hint to another process is governed by a
|
||||
ptrace access mode
|
||||
.B PTRACE_MODE_READ_REALCREDS
|
||||
check (see
|
||||
.BR ptrace (2));
|
||||
in addition,
|
||||
because of the performance implications of applying the hint,
|
||||
the caller must have the
|
||||
.B CAP_SYS_ADMIN
|
||||
capability.
|
||||
.\"
|
||||
.\" ======================================================================
|
||||
.\"
|
||||
|
@ -117,49 +157,6 @@ If a page is file-backed and dirty, it will be written back to the backing
|
|||
storage.
|
||||
The advice might be ignored for some pages in the range when it is not
|
||||
applicable.
|
||||
.PP
|
||||
The
|
||||
.I flags
|
||||
argument is reserved for future use; currently, this argument must be
|
||||
specified as 0.
|
||||
.PP
|
||||
The value specified in the
|
||||
.I vlen
|
||||
argument must be less than or equal to
|
||||
.BR IOV_MAX
|
||||
(defined in
|
||||
.I <limits.h>
|
||||
or accessible via the call
|
||||
.IR sysconf(_SC_IOV_MAX) ).
|
||||
.PP
|
||||
The
|
||||
.I vlen
|
||||
and
|
||||
.I iovec
|
||||
arguments are checked before applying any hints.
|
||||
If the
|
||||
.I vlen
|
||||
is too big, or
|
||||
.I iovec
|
||||
is invalid,
|
||||
then an error will be returned immediately and no advice will be applied.
|
||||
.PP
|
||||
The hint might be applied to a part of
|
||||
.I iovec
|
||||
if one of its elements points to an invalid memory region in the
|
||||
remote process.
|
||||
No further elements will be processed beyond that point.
|
||||
.PP
|
||||
Permission to provide a hint to another process is governed by a
|
||||
ptrace access mode
|
||||
.B PTRACE_MODE_READ_REALCREDS
|
||||
check (see
|
||||
.BR ptrace (2));
|
||||
in addition,
|
||||
because of the performance implications of applying the hint,
|
||||
the caller must have the
|
||||
.B CAP_SYS_ADMIN
|
||||
capability.
|
||||
.SH RETURN VALUE
|
||||
On success,
|
||||
.BR process_madvise ()
|
||||
|
|
Loading…
Reference in New Issue