Lee Schermerhorn

Misc cleanup of get_mempolicy(2):
+ mention that any mode flags will be saved with mode.
I don't bother to document mode flags here because we
already have a pointer to set_mempolicy(2) for more info
on memory policy.  mode flags are discussed there.
+ remove some old, obsolete [IMO] NOTES and 'roff comments.
This commit is contained in:
Michael Kerrisk 2008-08-08 19:47:20 +00:00
parent 1dd4e8b006
commit 63e28ad443
1 changed files with 13 additions and 33 deletions

View File

@ -22,7 +22,7 @@
.\" 2007-08-27, Lee Schermerhorn <Lee.Schermerhorn@hp.com>
.\" more precise specification of behavior.
.\"
.TH GET_MEMPOLICY 2 2007-08-27 Linux "Linux Programmer's Manual"
.TH GET_MEMPOLICY 2 2008-08-08 Linux "Linux Programmer's Manual"
.SH NAME
get_mempolicy \- Retrieve NUMA memory policy for a process
.SH SYNOPSIS
@ -53,6 +53,15 @@ then information about the calling process's default policy
(as set by
.BR set_mempolicy (2))
is returned.
The policy returned
.RI [ mode
and
.IR nodemask ]
may be used to restore the process's policy to its state at
the time of the call to
.BR get_mempolicy ()
using
.BR set_mempolicy (2).
If
.I flags
@ -72,8 +81,9 @@ If the
.I mode
argument is not NULL, then
.BR get_mempolicy ()
will store the policy mode of the requested NUMA policy in the location
pointed to by this argument.
will store the policy mode and any optional
.I "mode flags"
of the requested NUMA policy in the location pointed to by this argument.
If
.I nodemask
is not NULL, then the nodemask associated with the policy will be stored
@ -188,36 +198,6 @@ cases.)
.SH CONFORMING TO
This system call is Linux-specific.
.SH NOTES
If the mode of the process policy or the policy governing allocations at the
specified address is
.B MPOL_PREFERRED
and this policy was installed with an empty
.IR nodemask \(emspecifying
local allocation,
.BR get_mempolicy ()
will return the mask of on-line node IDs in the location pointed to by
a non-NULL
.I nodemask
argument.
This mask does not take into consideration any administratively imposed
restrictions on the process's context.
.\" FIXME
.\" "context" above refers to cpusets.
.\" No man page to reference. --Lee Schermerhorn
.\"
.\" Christoph says the following is untrue. These are "fully supported."
.\" Andi concedes that he has lost this battle and approves [?]
.\" updating the man pages to document the behavior. --Lee Schermerhorn
.\" This manual page is incomplete:
.\" it does not document the details the
.\" .BR MPOL_F_NODE
.\" flag,
.\" which modifies the operation of
.\" .BR get_mempolicy ().
.\" This is deliberate: this flag is not intended for application use,
.\" and its operation may change or it may be removed altogether in
.\" future kernel versions.
.\" .B Do not use it.
.SS "Versions and Library Support"
See
.BR mbind (2).