[SCSI] qla4xxx: add timeout handler
authorMike Christie <michaelc@cs.wisc.edu>
Wed, 15 Jul 2009 20:02:59 +0000 (15:02 -0500)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Thu, 30 Jul 2009 13:50:00 +0000 (08:50 -0500)
commit5c656af7e4edfe44c85034d6fa7002909f9c3c59
treece31cc38af5c2cabfc117f48b4b7806571dac8c9
parent94bced3c1b371014cbd187f2df5539b13a0e3b90
[SCSI] qla4xxx: add timeout handler

Recently dm-multipath began calling blk_abort_queue. This causes all the
commands/request running on the path to have the timeout function called.
If a path does go down, and the LLD returns DID_*, dm-multpiath will eventually
get this error and begin to call the cmd timeout handler. qla4xxx currently
does not set a timed out handler and so the default one could return
BLK_EH_NOT_HANDLED and end up firing the scsi eh and stopping IO to all
paths on the host when only one path is affected.

For software and offload iscsi we have a timed out handler already.
This patch adds a driver specific one to qla4xxx because there
are some ddb->state and session->state and command completion races
that are better handled in the LLD.

This also handles the problem where if the session is down,
we do not need the scsi eh to run until the transport code
has tried to reconnect us.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/qla4xxx/ql4_os.c