vm_releasep Kernel Service
Purpose
Releases virtual memory resources for the specified page range.
Syntax
Description
The vm_releasep kernel service releases pages for the specified page range in the virtual memory object. The values in the pfirst and npages parameters must be nonnegative.
Each page of the virtual memory object that intersects the page range (pfirst, pfirst + npages -1) is logically reset to 0, and any page frame is discarded. A page frame in the I/O state is marked for discard at I/O completion.
For working storage, paging-space disk blocks are freed and the storage-protect key is reset to the default value.
Note: All
of the pages to be released must be in the same virtual memory object.
Note: The vm_releasep subroutine
is not supported for use on large pages.
Parameters
Item | Description |
---|---|
vmid | Specifies the virtual memory object identifier. |
pfirst | Specifies the first page number in the specified page range. |
npages | Specifies the number of pages in the specified page range. |
Execution Environment
The vm_releasep kernel service can be called from the process environment only.
Return Values
Item | Description |
---|---|
0 | Indicates a successful operation. |
EINVAL | Indicates one of the following errors:
|