vm_invalidatep Kernel Service
Purpose
Releases page frames in the specified range for a non-journaled persistent segment or client segment.
Syntax
Parameters
| Item | Description | 
|---|---|
| sid | Identifies the base segment. | 
| pfirst | The first page number within the range. | 
| npages | The number of pages to invalidate starting from the pfirst value. All pages must be in the same segment. | 
Description
The vm_invalidatep kernel service routine discards any page frames associated with the virtual memory object in the specified page range.
If a page within the specified range is found in page-in or page-out state, then the thread is synchronously put to sleep until the page I/O completes. When the I/O is complete, any memory-resident page frame is then freed.
Note: The vm_invalidatep subroutine
is not supported for use on large pages.
Execution Environment
The vm_invalidatep kernel service can be called from the process environment only.
This is intended for files, and might not be called for working storage segments.
Return Values
| Item | Description | 
|---|---|
| 0 | Indicates the completion of the invalidating operations. | 
| EINVAL |  Indicates one of the following errors: 
  |