Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: John Garry <john.g.garry@oracle.com>
Cc: hch@lst.de, kbusch@kernel.org, sagi@grimberg.me, axboe@fb.com,
	linux-nvme@lists.infradead.org, John Garry <john.garry@linux.dev>
Subject: Re: [PATCH RFC] nvme-multipath: don't retry adding head disk
Date: Thu, 30 Jul 2026 13:40:09 +0200	[thread overview]
Message-ID: <20260730114009.GA25956@lst.de> (raw)
In-Reply-To: <20260729182235.366634-1-john.g.garry@oracle.com>

On Wed, Jul 29, 2026 at 06:22:35PM +0000, John Garry wrote:
> From: John Garry <john.garry@linux.dev>
> 
> If an attempt to add the head disk in nvme_mpath_set_live() ->
> device_add_disk() fails, then flag NVME_NSHEAD_DISK_LIVE is cleared and
> we bail out.
> 
> However, we may later call nvme_mpath_set_live() -> device_add_disk() again
> for another NS or from ANA updates for the same NS. This is broken, as we
> should not retry adding the disk - it breaks the driver model.
> 
> Add a flag NVME_NSHEAD_DISK_BROKEN to stop this happening.
> 
> Signed-off-by: John Garry <john.g.garry@oracle.com>
> ---
> I'm not happy with this solution, as we have a DOA disk and it would be
> better to remove the NSes in this case. OTOH, this device_add_disk()
> failure is very unlikely to happen, so we should not add a complex
> solution to handle it.

Yeah.  Broken is a bit weird of a name for something that would
either be a logic bug or a really messed up kernel, though.

I guess you arrive there by error injection?



  reply	other threads:[~2026-07-30 11:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-29 18:22 [PATCH RFC] nvme-multipath: don't retry adding head disk John Garry
2026-07-30 11:40 ` Christoph Hellwig [this message]
2026-07-30 13:04   ` John Garry

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=20260730114009.GA25956@lst.de \
    --to=hch@lst.de \
    --cc=axboe@fb.com \
    --cc=john.g.garry@oracle.com \
    --cc=john.garry@linux.dev \
    --cc=kbusch@kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=sagi@grimberg.me \
    /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