All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Wagner <dwagner@suse.de>
To: Christoph Hellwig <hch@lst.de>
Cc: Chris Leech <cleech@redhat.com>,
	linux-nvme@lists.infradead.org, sagi@grimberg.me,
	lengchao@huawei.com, hare@suse.de, mlombard@redhat.com,
	jmeneghi@redhat.com
Subject: Re: [RFC PATCH] nvme-multipath: break endless loop in nvme_round_robin_path
Date: Tue, 22 Mar 2022 13:07:27 +0100	[thread overview]
Message-ID: <20220322120727.k2drakwc4sr4rclq@carbon.lan> (raw)
In-Reply-To: <20220322111743.GC29151@lst.de>

On Tue, Mar 22, 2022 at 12:17:43PM +0100, Christoph Hellwig wrote:
> On Mon, Mar 21, 2022 at 03:43:03PM -0700, Chris Leech wrote:
> > This is a backstop for the odd loop construct in nvme_round_robin_path.
> > It counts how many times the head pointer has been passed, as that's the
> > only thing guarenteed to stay on the list.  Once is needed to start from
> > a different place and check the entire list, twice is excessive looping.
> 
> Shouldn't

d1bcf006a9d3 ("nvme-multipath: Early exit if no path is available")

> take care of this?

IIRC, this addressed the issue that we started to dereference a NULL
pointer if there was no path left.

Chris' problem is that the iterator always returns the same
pointer. Personally, I prefer the solution to introduce some sort of
sentinel over the one with the locking.


  reply	other threads:[~2022-03-22 12:07 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-21 22:43 nvme-multipath: round-robin infinite looping Chris Leech
2022-03-21 22:43 ` kdump details (Re: nvme-multipath: round-robin infinite looping) Chris Leech
2022-03-22 11:16   ` Christoph Hellwig
2022-03-22 15:36     ` Chris Leech
2022-03-21 22:43 ` [RFC PATCH] nvme-multipath: break endless loop in nvme_round_robin_path Chris Leech
2022-03-22 11:17   ` Christoph Hellwig
2022-03-22 12:07     ` Daniel Wagner [this message]
2022-03-22 15:42     ` Chris Leech
2022-03-21 22:43 ` [RFC PATCH] nvme: fix RCU hole that allowed for endless looping in multipath round robin Chris Leech
2022-03-23 14:54   ` Sagi Grimberg
2022-03-23 15:34     ` Christoph Hellwig
2022-03-23 19:07       ` John Meneghini
2022-04-05 13:14         ` John Meneghini
2022-03-25  6:36   ` Christoph Hellwig
2022-03-25 12:42   ` Sagi Grimberg
2022-04-05 17:25     ` Chris Leech

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=20220322120727.k2drakwc4sr4rclq@carbon.lan \
    --to=dwagner@suse.de \
    --cc=cleech@redhat.com \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=jmeneghi@redhat.com \
    --cc=lengchao@huawei.com \
    --cc=linux-nvme@lists.infradead.org \
    --cc=mlombard@redhat.com \
    --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 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.