Emulex Logo
OneCoreā„¢ Storage SDK Release 11.2
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
SCSI Initiator

Functions

int32_t ocs_scsi_ini_new_device (ocs_t *ocs)
 Initializes any initiator fields on the ocs structure. More...
 
int32_t ocs_scsi_ini_del_device (ocs_t *ocs)
 Tears down target members of ocs structure. More...
 
int32_t ocs_scsi_ini_new_domain (ocs_domain_t *domain)
 accept new domain notification More...
 
void ocs_scsi_ini_del_domain (ocs_domain_t *domain)
 accept domain lost notification More...
 
int32_t ocs_scsi_new_target (ocs_node_t *node)
 receive notification of a new SCSI target node More...
 
int32_t ocs_scsi_del_target (ocs_node_t *node, ocs_scsi_del_target_reason_e reason)
 Delete a SCSI target node. More...
 

Function Details

int32_t ocs_scsi_del_target ( ocs_node_t *  node,
ocs_scsi_del_target_reason_e  reason 
)

Delete a SCSI target node.

Description
Sent by base driver to notify a initiator-client that a remote target is now gone. The initiator-client should terminate and cleanup all I/O's associated with the node.

The ocs_node_t structure has and elment of type ocs_scsi_ini_node_t named ni_node that is declared and used by a target-server for private information.

This function is only called if the base driver is enabled for target capability.

Parameters
nodepointer node being deleted
reasonreason for deleting the target
Returns
Returns OCS_SCSI_CALL_ASYNC if target delete is queued for async completion and OCS_SCSI_CALL_COMPLETE if call completed or error.

Definition at line 258 of file ocs_ini_stub.c.

int32_t ocs_scsi_ini_del_device ( ocs_t *  ocs)

Tears down target members of ocs structure.

Description
Called by OS code when device is removed.
Parameters
ocspointer to ocs
Returns
returns 0 for success, a negative error code value for failure.

Definition at line 139 of file ocs_ini_stub.c.

void ocs_scsi_ini_del_domain ( ocs_domain_t *  domain)

accept domain lost notification

Description
Called by base-driver when a domain goes away. An initiator-client will use this call to clean up all domain scoped resources.

This function will only be called if the base-driver has been enabled for initiator capability.

Note that this call is made to initiator-client backends, the ocs_scsi_tgt_del_domain() function is called to target-server backends.

Parameters
domainpointer to domain
Returns
returns 0 for success, a negative error code value for failure.

Definition at line 197 of file ocs_ini_stub.c.

int32_t ocs_scsi_ini_new_device ( ocs_t *  ocs)

Initializes any initiator fields on the ocs structure.

Description
Called by OS initialization code when a new device is discovered.
Parameters
ocspointer to ocs
Returns
returns 0 for success, a negative error code value for failure.

Definition at line 121 of file ocs_ini_stub.c.

int32_t ocs_scsi_ini_new_domain ( ocs_domain_t *  domain)

accept new domain notification

Description
Called by base drive when new domain is discovered. An initiator-client will accept this call to prepare for new remote node notifications arising from ocs_scsi_new_target().

The domain context has the element ocs_scsi_ini_domain_t ini_domain which is declared by the initiator-client code and is used for initiator-client private data.

This function will only be called if the base-driver has been enabled for initiator capability.

Note that this call is made to initiator-client backends, the ocs_scsi_tgt_new_domain() function is called to target-server backends.

Parameters
domainpointer to domain
Returns
returns 0 for success, a negative error code value for failure.

Definition at line 166 of file ocs_ini_stub.c.

int32_t ocs_scsi_new_target ( ocs_node_t *  node)

receive notification of a new SCSI target node

Description
Sent by base driver to notify an initiator-client of the presense of a new remote target. The initiator-server may use this call to prepare for inbound IO from this node.

This function is only called if the base driver is enabled for initiator capability.

Parameters
nodepointer to new remote initiator node
Returns
none
Note

Definition at line 232 of file ocs_ini_stub.c.