Maps a real device number to the corresponding virtual device number for a given workload partition (WPAR).
Item | Description |
---|---|
wparid | WPAR identifier. This parameter is required. |
rdevno | Real device number. This parameter is required. |
vdevno | Points to the data area that will contain the virtual device number. This parameter is passed by reference. This parameter is optional. |
The kwpar_r2vmap_devno kernel service provides the ability to translate a real device number, maintained in the kernel device switch table, to the corresponding virtual device number maintained in the user space. The caller must specify an existing WPAR identifier with the wparid parameter and a valid real device number with the rdevno parameter. The kwpar_r2vmap_devno kernel service writes the corresponding virtual device number to the data area pointed to by the vdevno parameter (if specified). If the vdevno parameter is not specified, the return code indicates whether a mapping exists for the given WPAR identifier and real device number.
A mapping for the specified virtual device number must exist for the kwpar_v2rmap_devno kernel service to succeed.
The kwpar_r2vmap_devno kernel service can be called from the process environment only.
Item | Description |
---|---|
0 | Success. |
non-zero | Failure. |
The kwpar_r2vmap_devno service fails if one or more of the following errors occur:
Item | Description |
---|---|
EINVAL | Either the wparid or rdevno argument is invalid. |
ENXIO | Unable to locate the WPAR device map associated with the given WPAR ID. |
ESRCH | Unable to locate a mapping for the given real device number rdevno. |