madvise.2: Split EINVAL error into separate cases

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2015-02-03 14:15:33 +01:00
parent 845c8bea2d
commit ac95034e8a
1 changed files with 14 additions and 17 deletions

View File

@ -329,32 +329,29 @@ A kernel resource was temporarily unavailable.
The map exists, but the area maps something that isn't a file. The map exists, but the area maps something that isn't a file.
.TP .TP
.B EINVAL .B EINVAL
This error can occur for the following reasons: .I addr
.RS is not page-aligned or
.IP * 3
The value
.I length .I length
is negative. is negative.
.\" .I length .\" .I length
.\" is zero, .\" is zero,
.IP * .TP
.I addr .B EINVAL
is not page-aligned.
.IP *
.I advice .I advice
is not a valid value is not a valid.
.IP * .TP
The application is attempting to release locked or shared pages (with .B EINVAL
.BR MADV_DONTNEED ). .RB ( MADV_DONTNEED )
.IP * The application is attempting to release locked or shared pages.
.TP
.B EINVAL
.I advice
is
.BR MADV_MERGEABLE .BR MADV_MERGEABLE
or or
.BR MADV_UNMERGEABLE .BR MADV_UNMERGEABLE ,
was specified in
.IR advice ,
but the kernel was not configured with but the kernel was not configured with
.BR CONFIG_KSM . .BR CONFIG_KSM .
.RE
.TP .TP
.B EIO .B EIO
(for (for