madvise.2: MADV_REMOVE can be applied only to shared writable mappings

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2015-02-03 14:31:55 +01:00
parent 4335648dd1
commit 7208ad0a3d
1 changed files with 7 additions and 0 deletions

View File

@ -146,6 +146,7 @@ error
.\" bufferpool (shared memory segments) - without writing back to
.\" disk/swap space. This feature is also useful for supporting
.\" hot-plug memory on UML.
The specified address range must be mapped shared and writable.
This flag cannot be applied to locked pages or Huge TLB pages.
.TP
.BR MADV_DONTFORK " (since Linux 2.6.16)"
@ -324,6 +325,12 @@ On error, it returns \-1 and
is set appropriately.
.SH ERRORS
.TP
.B EACCES
.I advice
is
.BR MADV_REMOVE ,
but the specified address range is not a shared writable mapping.
.TP
.B EAGAIN
A kernel resource was temporarily unavailable.
.TP