public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Linton <jlinton@tributary.com>
To: "Bryn M. Reeves" <bmr@redhat.com>
Cc: Bart Van Assche <bvanassche@acm.org>,
	Hannes Reinecke <hare@suse.de>,
	"linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>,
	James Smart <james.smart@emulex.com>,
	James Bottomley <jbottomley@parallels.com>,
	Mike Christie <michaelc@cs.wisc.edu>
Subject: Re: [PATCH] scsi_transport_fc: Make 'port_state' writeable
Date: Mon, 18 Mar 2013 16:54:10 -0500	[thread overview]
Message-ID: <51478D02.5080404@tributary.com> (raw)
In-Reply-To: <514321FD.7090507@redhat.com>

On 3/15/2013 8:28 AM, Bryn M. Reeves wrote:
> On 03/15/2013 12:46 PM, Bart Van Assche wrote:
>> The SCSI EH keeps trying until all outstanding request have been 
>> finished. Does lpfc_host_reset_handler() invoke scsi_done() for
> 
> I don't think so (ends up calling lpfc_sli_cancel_iocbs() via 
> lpfc_hba_down_post() after shutting down the mailbox) but I've not seen the
> EH escalate all the way to host reset in most of my testing -
...
> The problem is that getting to this stage can take a very long time - much
> longer than most cluster's node eviction timer for e.g. which is the source
> of much of the complaint about this behaviour.

>> outstanding requests ? If not, how about modifying 
>> lpfc_host_reset_handler() such that it finishes all outstanding requests 
>> if the remote port is not reachable ?

	It does call the done() function on the outstanding command IOCBs after the
lpfc_reset_flush_io_context() call aborts them. The "problem" is that they are
returned with ScsiResult(DID_REQUEUE, 0) which basically queues them back to the
port as long as the port is still "up". Which results in the commands hanging
out until their timeouts expire (if the device isn't responding).

	If the device does resume after the reset, in the case of a tape device it is
possible corrupt the tape because the 2900's get trapped by the TUR in the eh
routines depending on which commands were hung. Take write for example, the
reset can result in a tape rewind, and when the write gets fired back at the
device the tape is at BOT and effectively erases all data already on the tape.
Whops!

	Also, as I stated elsewhere, in my testing its impossible to escalate beyond
the flush_io_context() in the lpfc_device_reset_handler driver because it always
returns true if the card firmware is responding.




  parent reply	other threads:[~2013-03-18 21:54 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-15 15:02 [PATCH] scsi_transport_fc: Make 'port_state' writeable Hannes Reinecke
2013-03-14 18:09 ` Steffen Maier
2013-03-15 11:55   ` Hannes Reinecke
2013-03-15 12:01     ` Bryn M. Reeves
2013-03-15 12:24     ` Bart Van Assche
2013-03-15 12:37       ` Bryn M. Reeves
2013-03-15 12:46         ` Bart Van Assche
2013-03-15 13:28           ` Bryn M. Reeves
2013-03-15 13:41             ` Bart Van Assche
2013-03-15 18:51               ` Mike Christie
2013-03-15 19:13                 ` Bart Van Assche
2013-03-15 21:12                   ` Mike Christie
2013-03-18  7:09                   ` Hannes Reinecke
2013-04-01 21:06                     ` James Smart
2013-04-04  6:26                       ` Hannes Reinecke
2013-04-05 15:14                         ` James Smart
2013-04-12 14:24                           ` Chad Dupuis
2013-03-18 21:54             ` Jeremy Linton [this message]
2013-04-01 20:51     ` James Smart

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=51478D02.5080404@tributary.com \
    --to=jlinton@tributary.com \
    --cc=bmr@redhat.com \
    --cc=bvanassche@acm.org \
    --cc=hare@suse.de \
    --cc=james.smart@emulex.com \
    --cc=jbottomley@parallels.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox