Open System Services Library Calls Reference Manual (G06.29+, H06.08+, J06.03+)
OSS Library Calls (g - h) HBA_GetAdapterPortAttributes(3)
EXAMPLES
HBA_STATUS status;
HBA_ADAPTERATTRIBUTES adapter_attributes;
HBA_PORTATTRIBUTES port_attributes;
status = HBA_GetAdapterAttributes(adapter_handle,
&adapter_attributes);
if (status == HBA_STATUS_OK) {
for (i = 0; i < adapter_attributes.NumberOfPorts; i++) {
status = HBA_GetAdapterPortAttributes(adapter_handle, i,
&port_attributes);
if (status == HBA_STATUS_OK) {
printf("Port %u has a Port FcID of %ld",i,
port_attributes.PortFcId);
}
}
}
RETURN VALUES
The HBA_GetAdapterPortAttributes( ) function returns these values:
HBA_STATUS_OK
The call to this function was successful.
HBA_STATUS_ERROR
An internal library or system error was detected.
HBA_STATUS_ERROR_BUSY
The library is busy processing a call that cannot be executed concurrently with
other calls and that might be modifying internal data structures.
HBA_STATUS_ERROR_INVALID_HANDLE
The handle passed to this function is invalid.
HBA_STATUS_ERROR_ARG
The pointer passed to this function is NULL.
HBA_STATUS_ERROR_UNAVAILABLE
The adapter to which the handle corresponds is not available.
HBA_STATUS_ERROR_ILLEGAL_INDEX
The port_index is invalid.
ERRORS
None.
RELATED INFORMATION
Functions: HBA_CloseAdapter(3), HBA_GetAdapterName(3),
HBA_GetFcpTargetMapping(3), HBA_GetNumberOfAdapters(3), HBA_GetVersion(3),
HBA_LoadLibrary(3), HBA_FreeLibrary(3), HBA_RefreshInformation(3).
Files: HBAAPI(5).
527187-017 Hewlett-Packard Company 3−177