diff --git a/man2/mprotect.2 b/man2/mprotect.2 index 203aad72a..1daffdd38 100644 --- a/man2/mprotect.2 +++ b/man2/mprotect.2 @@ -109,6 +109,18 @@ or specify one or more pages that are not mapped. (Before kernel 2.4.19, the error .BR EFAULT was incorrectly produced for these cases.) +.TP +.B ENOMEM +Changing the protection of a memory region would result in the total number of +mappings with distinct attributes (e.g., read versus read/write protection) +exceeding the allowed maximum. +.\" I.e., the number of VMAs would exceed the 64kB maximum +(For example, making the protection of a range +.BR PROT_READ +in the middle of a region currently protected as +.BR PROT_READ|PROT_WRITE +would result in three mappings: +two read/write mappings at each end and a read-only mapping in the middle.) .SH CONFORMING TO SVr4, POSIX.1-2001. .\" SVr4 defines an additional error