]> git.karo-electronics.de Git - karo-tx-linux.git/commit
libiscsi: Fix recovery slowdown regression
authorMike Christie <michaelc@cs.wisc.edu>
Tue, 9 Mar 2010 20:14:51 +0000 (14:14 -0600)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 26 Apr 2010 14:47:47 +0000 (07:47 -0700)
commit0a5693e82c90479a012c903915fa970c7bf22593
tree31673ab9dd0c09b1e633f0b4b34196541537d23c
parent14d209ccb3a6eb7916f1d282e586afe8fd01b1dd
libiscsi: Fix recovery slowdown regression

commit 4ae0a6c15efcc37e94e3f30e3533bdec03c53126 upstream.

We could be failing/stopping a connection due to libiscsi starting
recovery/cleanup, but the xmit path or scsi eh thread path
could be dropping the connection at the same time.

As a result the session->state gets set to failed instead of in
recovery. We end up not blocking the session
and so the replacement timeout never gets started and we only end up
failing the IO when scsi_softirq_done sees that the
cmd has been running for (cmd->allowed + 1) * rq->timeout secs.

We used to fail the IO right away so users are seeing a long
delay when using dm-multipath. This problem was added in
2.6.28.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/scsi/libiscsi.c