Re: [PATCH 0/1] scsi: Handle MLQUEUE busy response in scsi_send_eh_cmnd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Quoting James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx>:

On Mon, 2013-04-15 at 16:55 -0500, Brian King wrote:
On 04/15/2013 03:45 PM, James Bottomley wrote:
> On Mon, 2013-04-15 at 13:39 -0500, wenxiong@xxxxxxxxxxxxxxxxxx wrote:
>> In scsi_send_eh_cmnd(), this fix will check the return code of queuecomamnd
>> when sending commands and retry for a bit if the driver returns a
>> busy response.
>
> This is already handled by the timeout, I think.  If a driver
> continuously returns MLQUEUE BUSY, then we'll fail the request after the
> timeout on the command expires.

If we get a timeout in scsi_send_eh_cmnd we call scsi_abort_eh_cmnd. If the
abort works, we return FAILED out of scsi_send_eh_cmnd, which results in
no retry being performed, since scsi_eh_tur only retries once and
only if NEEDS_RETRY is returned. Or am I missing something?

Sorry, I'm not being clear.  It comes with being at a conference.  What
I mean is that if you do this, the criterion for success or faiure
should be the amount of time left not the number of retries.  This is
what the non-eh submission path also does for retries of events that
don't count against the retry limit ... so something like this patch
(uncompiled and untested #include stddisclaimer.h)

James

Hi James,

The failing case for us is: Doesn't matter what timeout value we set in
wait_for_completion_timeout(), it always returns with timeleft = 0.
For example, if I set timeout = 50 secs, wait_for_completion_timeout()
always returns with timeleft =0(even adapter is already in good shape in
20 secs).  We never gets a chance to call into if (timeleft) leg.

My understanding is: if shost->host->queuecommand() failed with MLQUEUE busy
response at the first time, wait_for_completion_timeout() always wakes up by expired.

Here is log when I enabled scsi log:

Apr 15 18:44:35 ltcsatiocp5 kernel: scsi_send_eh_cmnd: scmd: c0000000f88bc980, timeleft: 0

I applied your patch. Because timeleft is always zero, never got a chance to call into
if(timeleft) { leg.

Thanks,
Wendy

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux