Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: hare@suse.de (Hannes Reinecke)
Subject: [PATCH] nvme: do not block connect call on inaccessible devices
Date: Tue, 5 Jun 2018 14:23:18 +0200	[thread overview]
Message-ID: <20180605142318.7d566c27@pentland.suse.de> (raw)
In-Reply-To: <20180605111746.GA5802@lst.de>

On Tue, 5 Jun 2018 13:17:46 +0200
Christoph Hellwig <hch@lst.de> wrote:

> On Tue, Jun 05, 2018@10:29:05AM +0200, Hannes Reinecke wrote:
> > When a device is in ANA inaccessible state the call to 'nvme
> > connect' will hang as a parition scan is triggered and the I/O will
> > be requeued indefinitely.
> > Or rather, requeued until the next path is connected, but we cannot
> > issue any nvme ioctls anymore as the nvmf_dev_mutex is blocked by
> > the initial 'connect' call.
> > 
> > This patch inhibits partition scan if no working paths are found,
> > and retriggers the partition scan once the device becomes active.  
> 
> And what updates the state once all your inaccessible or change
> state groups become optimized?
> 
ANA AENs?
Someone told me we should rely on ANA AENS or the system is hosed
anyway :-)

My idea was to hook into the 'revalidate_disk' call here, but then this
approach turned out to be easier.

> Also I see no point registering the disk if we can't do I/O to it.
> 
> I'd rather prefer something along the lines of the completely untested
> patch below if we really want to go down this route:
> 
Okay, I'll give it a go.

Cheers,

Hannes

  reply	other threads:[~2018-06-05 12:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-05  8:29 [PATCH] nvme: do not block connect call on inaccessible devices Hannes Reinecke
2018-06-05 11:17 ` Christoph Hellwig
2018-06-05 12:23   ` Hannes Reinecke [this message]
2018-06-05 12:35     ` Bart Van Assche
2018-06-05 12:50       ` hch
2018-06-05 12:51     ` Christoph Hellwig

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=20180605142318.7d566c27@pentland.suse.de \
    --to=hare@suse.de \
    /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