Deletes a virtual memory object.
#include <sys/types.h> #include <sys/errno.h> #include <sys/vmuser.h>
int vms_delete (vmid) vmid_t vmid;
vmid | Specifies the ID of the virtual memory object to be deleted. |
The vms_delete kernel service deallocates the temporary resources held by the virtual memory object specified by the vmid parameter and then frees the control block. This delete operation can complete asynchronously, but the caller receives a synchronous return code indicating success or failure.
The completion of the delete operation can be delayed if paging I/O is still occurring for pages attached to the object. All page frames not in the I/O state are released.
If there are page frames in the I/O state, they are marked for discard at I/O completion and the virtual memory object is placed in the iodelete state. When an I/O completion occurs for the last page attached to a virtual memory object in the iodelete state, the virtual memory object is placed on the free list.
The vms_delete kernel service can be called from the process environment only.
0 | Indicates a successful operation. |
EINVAL | Indicates that the vmid parameter is not valid. |
The vms_delete kernel service is part of Base Operating System (BOS) Runtime.
The vms_create kernel service.
Memory Kernel Services and Understanding Virtual Memory Manager Interfaces in AIX Kernel Extensions and Device Support Programming Concepts.