diff options
author | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-12-15 15:13:27 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-12-16 14:38:52 -0500 |
commit | a6da74cb077e88a604e5b2a6663b44c221f0ae75 (patch) | |
tree | 77f566c212282f8925dae4b1a960dc241087e2fb | |
parent | 02bd3499a3be984f1e88821c3ed252c8c49c498e (diff) |
[SCSI] mpt fusion: clear list of outstanding commands on host reset
A bug in the fusion driver was exposed by the switch to block timeout.
Basically, drivers are supposed to terminate commands once error
handling begins on them. The fusion apparently wasn't doing this.
Under the old timeout regime, completions on terminated commands would
by and large get ignored because of the way command timeouts used to
work. The new block timers are very intolerant to this, though,
becuase the request gets cleaned and freed.
Fixes: http://bugzilla.kernel.org/show_bug.cgi?id=12195
Reported-by: Alex Shi <alex.shi@intel.com>
Tested-by: Ming Lin <ming.m.lin@intel.com>
Cc: Eric Moore <Eric.Moore@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
-rw-r--r-- | drivers/message/fusion/mptscsih.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/mptscsih.c index d62fd4f6b52e..ee090413e598 100644 --- a/drivers/message/fusion/mptscsih.c +++ b/drivers/message/fusion/mptscsih.c | |||
@@ -2008,6 +2008,9 @@ mptscsih_host_reset(struct scsi_cmnd *SCpnt) | |||
2008 | return FAILED; | 2008 | return FAILED; |
2009 | } | 2009 | } |
2010 | 2010 | ||
2011 | /* make sure we have no outstanding commands at this stage */ | ||
2012 | mptscsih_flush_running_cmds(hd); | ||
2013 | |||
2011 | ioc = hd->ioc; | 2014 | ioc = hd->ioc; |
2012 | printk(MYIOC_s_INFO_FMT "attempting host reset! (sc=%p)\n", | 2015 | printk(MYIOC_s_INFO_FMT "attempting host reset! (sc=%p)\n", |
2013 | ioc->name, SCpnt); | 2016 | ioc->name, SCpnt); |