From: James Smart <James.Smart@Emulex.Com>
To: michaelc@cs.wisc.edu
Cc: linux-scsi@vger.kernel.org
Subject: Re: [PATCH 2/4] scsi: add transport host byte errors
Date: Thu, 15 Mar 2007 09:20:43 -0400 [thread overview]
Message-ID: <45F9482B.4050100@emulex.com> (raw)
In-Reply-To: <11739019703157-git-send-email-michaelc@cs.wisc.edu>
michaelc@cs.wisc.edu wrote:
> fast_io_fail_tmo
> iscsi: session recovery_tmo
> fc: rport fast_io_fail_tmo
>
> The difference is that when the timer fires, for iscsi we unblock the
> queue and fail commands in the blocked queue. FC just fails IO running
> in the driver/fw/hw. The IO in the blocked queue sits there until dev_loss_tmo.
True - FC contacted the LLDD to terminate i/o, who has no notion of any io
that has yet to be sent to it via queuecommand(). Blocked i/o sits until
dev_loss_tmo, as that is when the sdev gets torn down. Perhaps a block layer call
should be created, that the FC transport can call, to terminate the blocked
queue. Thoughts ?
> dev_loss_tmo
> iscsi: none yet (we are working on it :))
> fc: dev_loss_tmo
>
> Currently, if there is a transport problem the iscsi drivers will return
> outstanding commands (commands being exeucted by the driver/fw/hw) with
> DID_BUS_BUSY and block the session so no new commands can be queued.
> Commands that are caught between the failure handling and blocking are
> failed with DID_IMM_RETRY or one of the scsi ml queuecommand return values.
> When the recovery_timeout fires, the iscsi drivers then fail IO with
> DID_NO_CONNECT.
>
> For fcp, some drivers will fail some outstanding IO (disk but possibly not
> tape) with DID_BUS_BUSY or some other value that causes a retry and hits
> the scsi_error.c failfast check, block the rport, and commands caught in the
> race are failed with DID_IMM_RETRY. Other drivers, will hold onto all IO
> and wait for the terminate_rport_io or dev_loss_tmo_callbk to be called.
> In this case lpfc, could return the IO with DID_ERROR.
Note: Variability in behavior has to be allowed as both implementations are
within FC specification. Also, the "everything killed" scenario is a valid
worst case behavior that can always occur. The "it's not killed immediately"
scenario is an optimization towards best-case behavior (with better FC-MI-2
compliance).
Lpfc returns DID_ERROR as the io requests had been queued to the adapter,
may have gone out on the wire, and may have changed media. They were terminated
early based on the respective timeout. Thus, a BUSY status, which implies
no media change, is deemed inappropriate. Based on the conversation, you
are implying that the layer above, which asked for the fastfail may want to
distinguish between an io terminated due to the fastfail timeout vs an io
that failed due to a real error. Easy enough to do - we just need a new
return status. And, I see, that's what the patch below does.
So far, so good....
-- james s
next prev parent reply other threads:[~2007-03-15 13:20 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-14 19:52 RFC: add transport host byte values and common failure behavior michaelc
2007-03-14 19:52 ` [PATCH 1/4] iscsi class, qla4xxx and libiscsi: export iscsi session state in sysfs michaelc
2007-03-14 19:52 ` [PATCH 2/4] scsi: add transport host byte errors michaelc
2007-03-14 19:52 ` [PATCH 3/4] iscsi class, libiscsi and qla4xxx: convert to new transport host byte values michaelc
2007-03-14 19:52 ` [PATCH 4/4] fc class: use " michaelc
2007-03-14 20:11 ` [PATCH 2/4] scsi: add transport host byte errors Mike Christie
2007-03-14 21:14 ` Mike Christie
2007-03-15 13:41 ` [PATCH 4/4] fc class: use transport host byte values James Smart
2007-03-15 14:26 ` Mike Christie
2007-03-15 14:45 ` James Smart
2007-03-15 13:20 ` James Smart [this message]
2007-03-15 14:52 ` [PATCH 2/4] scsi: add transport host byte errors Mike Christie
2007-03-15 16:33 ` James Smart
2007-03-15 12:58 ` [PATCH 1/4] iscsi class, qla4xxx and libiscsi: export iscsi session state in sysfs James Smart
2007-03-15 14:20 ` Mike Christie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45F9482B.4050100@emulex.com \
--to=james.smart@emulex.com \
--cc=linux-scsi@vger.kernel.org \
--cc=michaelc@cs.wisc.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.