Go to main content

man pages section 3: Extended Library Functions, Volume 4

Exit Print View

Updated: Wednesday, July 27, 2022
 
 

stmfValidateViewEntryList (3STMF)

Name

stmfValidateViewEntryList - validate/get logical unit numbers for view entry list

Synopsis

cc [ flag... ] file... –
lstmf [ library... ]
#include <libstmf.h>

int stmfValidateViewEntryList(
stmfGuid *logicalUnit, 
stmfViewEntryList *viewEntryList
, void **opData);

Parameters

logicalUnit

The identifier of the logical unit to which all view entries in the list need to be validated.

viewEntryList

The list of view entries to be validated to the specified logical unit identifier.

opData

A pointer to a pointer to void. On successful return, this parameter contains the information about the list of view entries validated and the LU numbers assigned. But on failure, this parameter may contain appropriate information depending on the error value returned. For some type of failures, it is set to NULL.

Description

The stmfValidateViewEntryList() function validates the logical unit numbers for the list of views passed to the function. This is done by setting view-> luNbrValid to B_TRUE and setting view->luNbr to the logical unit number for all required view entries in the list.

The stmfValidateViewEntryList() function finds non conflicting available logical unit numbers for those view entries in the given list by setting view-> luNbrValid to B_FALSE. On Success, opData variable can be used to return validated view entries with selected LU numbers. On failure, if needed opData can be used to return detailed error information. If the library returns data through opData parameter, the caller should call stmfFreeMemory(3STMF) when that data is no longer needed.

Return Values

The following values are returned:

STMF_STATUS_SUCCESS

The API call was successful. On successful completion, opData parameter is set to a pointer to a pointer to stmfViewList structure with the information about validated view entries.

STMF_ERROR_INVALID_TG

One or more target group names mentioned in the view entry structure are invalid. This failure sets opData to a pointer to pointer to stmfViewList structure with view entries which caused this error.

STMF_ERROR_INVALID_HG

One or more host group name mentioned in the view entry structure are invalid. This failure sets opData to a pointer to pointer to stmfViewList structure with view entries which caused this error.

STMF_ERROR_INVALID_ARG

One or more view entries has invalid values. Examples for invalid view entry value is, providing bad luNbr field with luNbrValid field set to TRUE. This failure sets opData to a pointer to pointer to stmfViewList struct with view entries which caused this error.

STMF_ERROR_VE_CONFLICT

The list of view entries can not possibly be added to the given logical unit because such addition will cause unresolvable conflicts with existing view entries in the system or with the entries in the given list itself. This failure also sets opData with a pointer to pointer to stmfViewList structure with a list of view entries which caused the conflict.

Attributes

See attributes(7) for descriptions of the following attributes:

ATTRIBUTE TYPE
ATTRIBUTE VALUE
Interface Stability
Committed
MT-Level
Safe

See Also

libstmf(3LIB), stmfAddViewEntry(3STMF), attributes(7)