DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

sdi_bus_reset(D3sdi)


sdi_bus_reset -- send SFB_BUS_RESET to HBA driver

Synopsis

   #include <sys/sdi.h>
   

int sdi_bus_reset(struct scsi_adr *sap, struct sb *sbp);

Description

sdi_bus_reset( ) sends an SFB_BUS_RESET function to the HBA driver that corresponds to sap. Prior to doing this, it sends SFB_SUSPEND to all Logical Units on the bus. Upon completion, it calls sdi_timeout(D3sdi) to wait for 4 seconds, giving devices time to fully reset. After this timeout period passes, SFB_RESUME is sent to all Logical Units on the bus that are not waiting to be serviced by the error recovery gauntlet.

Arguments


sap
SCSI bus to be reset

sbp
partially completed command block to be sent to HBA driver

Return values

The normal return is SDI_RET_OK. Any other return value indicates a failure.

Usage

sdi_bus_reset( ) is used by target drivers as part of error recovery. It must only be called from the target driver's error recovery routine as a result of a corresponding sdi_start_gauntlet(D3sdi) call.

sbp is assumed to have its sf_dev filled out with the SCSI address to which the SFB_BUS_RESET should be sent. Also, sbp->SFB.sf_func must be set to the function to be called upon completion.

Context and synchronization

Blockable context.

Driver-defined basic locks, read/write locks, and sleep locks can be held across calls to this function.

Applicable hardware

All

Version applicability

sdi: 3, 4 target drivers.

References

sdi_device_reset(D3sdi), sdi_end_gauntlet(D3sdi), sdi_start_gauntlet(D3sdi), sdi_timeout(D3sdi)

``SDI bus timeout/reset recovery'' in HDK Technical Reference


19 June 2005
© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 6 and UnixWare (SVR5) HDK - June 2005