|Skip Navigation Links|
|Exit Print View|
|man pages section 3: Extended Library Functions Oracle Solaris 10 8/11 Information Library|
- create or free local memory handle
cc [ flag... ] file... –lrsm [ library... ] #include <rsmapi.h> int rsm_create_localmemory_handle( rsmapi_controller_handle_t handle, rsm_localmemory_handle_t *l_handle, caddr_t local_vaddr, size_t length);
int rsm_free_localmemory_handle( rsmapi_controller_handle_t handle, rsm_localmemory_handle_t l_handle);
The rsm_create_localmemory_handle() function creates a local memory handle to be used in the I/O vector component of a scatter-gather list of subsequent rsm_memseg_import_putv() and rsm_memseg_import_getv() calls. The handle argument specifies the controller handle obtained from rsm_get_controller(3RSM). The l_handle argument is a pointer to the location for the function to return the local memory handle. The local_vaddr argument specifies the local virtual address; it should be aligned at a page boundary. The length argument specifies the length of memory spanned by the handle.
The rsm_free_localmemory_handle() function unlocks the memory range for the local handle specified by l_handle and releases the associated system resources. The handle argument specifies the controller handle. All handles created by a process are freed when the process exits, but the process should call rsm_free_localmemory_handle() as soon as possible to free the system resources.
Upon successful completion, these functions return 0. Otherwise, an error value is returned to indicate the error.
The rsm_create_localmemory_handle() and rsm_free_localmemory_handle() functions can return the following errors:
Invalid controller handle.
Invalid local memory handle.
The rsm_create_localmemory_handle() function can return the following errors:
See attributes(5) for descriptions of the following attributes: