Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: keith.busch@intel.com (Keith Busch)
Subject: [PATCH] nvme: Fix disk names when not using nvme multipath
Date: Wed, 18 Apr 2018 09:34:11 -0600	[thread overview]
Message-ID: <20180418153410.GM11513@localhost.localdomain> (raw)
In-Reply-To: <20180418150429.GA7862@lst.de>

On Wed, Apr 18, 2018@05:04:29PM +0200, Christoph Hellwig wrote:
> On Wed, Apr 18, 2018@07:26:58AM -0600, Keith Busch wrote:
> > No-can-do. If we did that with nvme-multipath, we could find NMIC
> > namespaces using the susbystem instance for the disk name, and non-NMIC
> > using the controller instance: we'll have a different set of name
> > conflicts to deal with.
> 
> True.  ? think I was also trying to solve the wrong problem to start
> with, that's what happens if you get up a 4am :)
> 
> Another just as completely untested attempt below:

It's a bit of an eyesore, but looks like it will work for the most
part. :)
 
> diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
> index 197a6ba9700f..ffca28dd2836 100644
> --- a/drivers/nvme/host/core.c
> +++ b/drivers/nvme/host/core.c
> @@ -68,6 +68,11 @@ static bool streams;
>  module_param(streams, bool, 0644);
>  MODULE_PARM_DESC(streams, "turn on support for Streams write directives");
>  
> +bool multipath = true;
> +module_param(multipath, bool, 0644);

I think the permissions just have to be 0444 so that the user can't change the
naming method after some disks were named with the alternate method.

> +MODULE_PARM_DESC(multipath,
> +	"turn on native support for multiple controllers per subsystem");

  reply	other threads:[~2018-04-18 15:34 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-17 22:03 [PATCH] nvme: Fix disk names when not using nvme multipath Keith Busch
2018-04-18  6:44 ` Christoph Hellwig
2018-04-18 13:26   ` Keith Busch
2018-04-18 15:04     ` Christoph Hellwig
2018-04-18 15:34       ` Keith Busch [this message]
2018-04-18 15:34         ` Christoph Hellwig
2018-04-18 16:09           ` Keith Busch
2018-04-19  8:50             ` 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=20180418153410.GM11513@localhost.localdomain \
    --to=keith.busch@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox