summaryrefslogtreecommitdiffstats
path: root/lib/libc/sys/mlock.2
diff options
context:
space:
mode:
authormpp <mpp@FreeBSD.org>1996-08-22 23:31:07 +0000
committermpp <mpp@FreeBSD.org>1996-08-22 23:31:07 +0000
commit5e0b8a523431b6adfab8ac667e002985816ad527 (patch)
tree748859d8821f0dc6e8312554558994563f756b27 /lib/libc/sys/mlock.2
parente9dba4b462df04cf03473f2e6881efb52dd69c32 (diff)
downloadFreeBSD-src-5e0b8a523431b6adfab8ac667e002985816ad527.zip
FreeBSD-src-5e0b8a523431b6adfab8ac667e002985816ad527.tar.gz
Correctly use .Fn instead of .Nm to reference function names
in a bunch of man pages. Use the correct .Bx (BSD UNIX) or .At (AT&T UNIX) macros instead of explicitly specifying the version in the text in a bunch of man pages.
Diffstat (limited to 'lib/libc/sys/mlock.2')
-rw-r--r--lib/libc/sys/mlock.225
1 files changed, 13 insertions, 12 deletions
diff --git a/lib/libc/sys/mlock.2 b/lib/libc/sys/mlock.2
index 90bb7c7..15ce741 100644
--- a/lib/libc/sys/mlock.2
+++ b/lib/libc/sys/mlock.2
@@ -47,7 +47,7 @@
.Fn munlock "caddr_t addr" "size_t len"
.Sh DESCRIPTION
The
-.Nm mlock
+.Fn mlock
system call
locks into memory the physical pages associated with the virtual address
range starting at
@@ -56,9 +56,9 @@ for
.Fa len
bytes.
The
-.Nm munlock
+.Fn munlock
call unlocks pages previously locked by one or more
-.Nm mlock
+.Fn mlock
calls.
For both, the
.Fa addr
@@ -70,7 +70,7 @@ to be so.
The entire range must be allocated.
.Pp
After an
-.Nm mlock
+.Fn mlock
call, the indicated pages will cause neither a non-resident page
nor address-translation fault until they are unlocked.
They may still cause protection-violation faults or TLB-miss faults on
@@ -81,12 +81,12 @@ Multiple processes may have the same physical pages locked via their own
virtual address mappings.
A single process may likewise have pages multiply-locked via different virtual
mappings of the same pages or via nested
-.Nm mlock
+.Fn mlock
calls on the same address range.
Unlocking is performed explicitly by
-.Nm munlock
+.Fn munlock
or implicitly by a call to
-.Nm munmap
+.Fn munmap
which deallocates the unmapped address range.
Locked mappings are not inherited by the child process after a
.Xr fork 2 .
@@ -94,7 +94,7 @@ Locked mappings are not inherited by the child process after a
Since physical memory is a potentially scarce resource, processes are
limited in how much they can lock down.
A single process can
-.Nm mlock
+.Fn mlock
the minimum of
a system-wide ``wired pages'' limit and
the per-process
@@ -138,11 +138,11 @@ Some portion of the indicated address range is not locked.
.Xr getpagesize 3
.Sh BUGS
Unlike The Sun implementation, multiple
-.Nm mlock
+.Fn mlock
calls on the same address range require the corresponding number of
-.Nm munlock
+.Fn munlock
calls to actually unlock the pages, i.e.
-.Nm mlock
+.Fn mlock
nests.
This should be considered a consequence of the implementation
and not a feature.
@@ -158,4 +158,5 @@ The
.Fn mlock
and
.Fn munlock
-functions first appeared in 4.4BSD.
+functions first appeared in
+.Bx 4.4 .
OpenPOWER on IntegriCloud