All of lore.kernel.org
 help / color / mirror / Atom feed
From: james.smart@broadcom.com (James Smart)
Subject: [PATCH 2/3] nvme: avoid reconnection for the discovery controller
Date: Thu, 24 May 2018 13:30:55 -0700	[thread overview]
Message-ID: <4a3d1fbb-ba38-9488-ab38-9ae85ec18922@broadcom.com> (raw)
In-Reply-To: <20180524141817.127576-3-hare@suse.de>



On 5/24/2018 7:18 AM, Hannes Reinecke wrote:
> If the connection to the discovery controller fails for whatever
> reason we should not attempt to reconnect; rather the user should
> retry the discovery altogether.
>
> Signed-off-by: Hannes Reinecke <hare at suse.com>
> ---
>   drivers/nvme/host/fabrics.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/drivers/nvme/host/fabrics.c b/drivers/nvme/host/fabrics.c
> index d25aa4322d16..997d8677ab44 100644
> --- a/drivers/nvme/host/fabrics.c
> +++ b/drivers/nvme/host/fabrics.c
> @@ -474,6 +474,9 @@ EXPORT_SYMBOL_GPL(nvmf_connect_io_queue);
>   
>   bool nvmf_should_reconnect(struct nvme_ctrl *ctrl)
>   {
> +	if (ctrl->opts->discovery_nqn)
> +		return false;
> +
>   	if (ctrl->opts->max_reconnects != -1 &&
>   	    ctrl->nr_reconnects < ctrl->opts->max_reconnects)
>   		return true;

um no.? It should follow the same reconnect policies as anything other 
controller.?? There is no guarantee the event that triggered the 
discovery controller will do so again. Not all discovery controller 
connects are manually initiated by an admin.?? So failing the reconnect 
may mean you will never reconnect with the subsystems described by the 
discovery controller.

-- james

  reply	other threads:[~2018-05-24 20:30 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-24 14:18 [PATCH 0/3] nvme: fix stuck discovery Hannes Reinecke
2018-05-24 14:18 ` [PATCH 1/3] nvme: centralize discovery controller defaults Hannes Reinecke
2018-05-24 20:31   ` James Smart
2018-05-25  8:55   ` Christoph Hellwig
2018-05-24 14:18 ` [PATCH 2/3] nvme: avoid reconnection for the discovery controller Hannes Reinecke
2018-05-24 20:30   ` James Smart [this message]
2018-05-25  6:43     ` Hannes Reinecke
2018-05-24 14:18 ` [PATCH 3/3] nvme: allow duplicate connections to " Hannes Reinecke
2018-05-24 20:31   ` James Smart
2018-05-25  8:56   ` Christoph Hellwig
2018-06-18 16:11   ` James Smart
2018-06-18 22:54     ` Hannes Reinecke
2018-06-18 23:57       ` James Smart
2018-06-19 10:05         ` Hannes Reinecke

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=4a3d1fbb-ba38-9488-ab38-9ae85ec18922@broadcom.com \
    --to=james.smart@broadcom.com \
    /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.