Home
Main website
Display Sidebar
Hide Ads
Recent Changes
View Source:
munlock(2)
Edit
PageHistory
Diff
Info
LikePages
!!NAME munlock - reenable paging for some parts of memory !!SYNOPSIS __#include <sys/mman.h>__ __int munlock(const void *__''addr''__, size_t__ ''len''__);__ !!DESCRIPTION __munlock__ reenables paging for the memory in the range starting at ''addr'' with length ''len'' bytes. All pages which contain a part of the specified memory range can after calling __munlock__ be moved to external swap space again by the kernel. Memory locks do not stack, i.e., pages which have been locked several times by calls to __mlock__ or __mlockall__ will be unlocked by a single call to __munlock__ for the corresponding range or by __munlockall__. Pages which are mapped to several locations or by several processes stay locked into RAM as long as they are locked at least at one location or by at least one process. On POSIX systems on which __mlock__ and __munlock__ are available, ___POSIX_MEMLOCK_RANGE__ is defined in __PAGESIZE__ from <limits.h> indicates the number of bytes per page. !!RETURN VALUE On success, __munlock__ returns zero. On error, -1 is returned, ''errno'' is set appropriately, and no changes are made to any locks in the address space of the process. !!ERRORS ;[ENOMEM]: Some of the specified address range does not correspond to mapped pages in the address space of the process. ;[EINVAL]: ''len'' was not a positive number. !!CONFORMING TO POSIX.1b, SVr4 !!SEE ALSO mlock(2), mlockall(2), munlockall(2)
7 pages link to
munlock(2)
:
Man2m
sched_getscheduler(2)
sched_setscheduler(2)
syscalls(2)
mlock(2)
mlockall(2)
munlockall(2)
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.