]> err.no Git - linux-2.6/commit
[SCSI] ibmvscsi: requeue while CRQ closed
authorRobert Jennings <rcj@linux.vnet.ibm.com>
Mon, 12 Nov 2007 15:00:23 +0000 (09:00 -0600)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Sat, 12 Jan 2008 00:22:45 +0000 (18:22 -0600)
commit860784c8a2b077157b6a51fb8749524d0363cc49
tree720d50af0b50e65969d313e9ae62966f5b8d02ac
parentdc8875e1078961591af4fbf9556c44648bf28d11
[SCSI] ibmvscsi: requeue while CRQ closed

CRQ send errors that return with H_CLOSED should return with
SCSI_MLQUEUE_HOST_BUSY until firmware alerts the client of a CRQ
transport event.  The transport event will either reinitialize and
requeue the requests or fail and return IO with DID_ERROR.

To avoid failing the eh_* functions while re-attaching to the server
adapter this will retry for a period of time while ibmvscsi_send_srp_event
returns SCSI_MLQUEUE_HOST_BUSY.

In ibmvscsi_eh_abort_handler() the loop includes the search of the
event list.  The lock on the hostdata is dropped while waiting to try
again after failing ibmvscsi_send_srp_event.  The event could have been
purged if a login was in progress when the function was called.

In ibmvscsi_eh_device_reset_handler() the loop includes the call to
get_event_struct() because a failing call to ibmvscsi_send_srp_event()
will have freed the event struct.

Signed-off-by: Robert Jennings <rcj@linux.vnet.ibm.com>
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/ibmvscsi/ibmvscsi.c