mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: John Meneghini <jmeneghi@redhat.com>
To: Caleb Sander Mateos <csander@purestorage.com>
Cc: kbusch@kernel.org, hch@lst.de, sagi@grimberg.me,
	loberman@redhat.com, linux-nvme@lists.infradead.org,
	linux-kernel@vger.kernel.org, emilne@redhat.com,
	bgurney@redhat.com
Subject: Re: [PATCH v3 3/5] nvme: add the NVME_ENABLE_MULTIPATH_PARAM config option
Date: Mon, 31 Mar 2025 10:28:55 -0400	[thread overview]
Message-ID: <e22e3cd8-f792-4f20-9624-76e973cf4940@redhat.com> (raw)
In-Reply-To: <CADUfDZoXg39h-5gi+aVj2u1H6HC4Beyp2XPTrjJ_PMDPf11dQg@mail.gmail.com>

On 3/28/25 3:49 PM, Caleb Sander Mateos wrote:
>>   bool multipath = true;
>> +#ifdef CONFIG_NVME_ENABLE_MULTIPATH_PARAM
>>   module_param(multipath, bool, 0444);
>>   MODULE_PARM_DESC(multipath,
>>          "turn on native support for multiple controllers per subsystem");
>> +#endif
> If CONFIG_NVME_ENABLE_MULTIPATH_PARAM is disabled, could you #define
> multipath false in place of the global variable? That would allow the
> compiler to optimize out the multipath checks and the resulting dead
> code.

If we #define multipath to be false that would permanently disable the multipath code
when CONFIG_NVME_ENABLE_MULTIPATH_PARAM=n, and this is not what we want. The purpose
of CONFIG_NVME_ENABLE_MULTIPATH_PARAM=n is to simply remove the core_nvme.multipath
parameter from the kernel so the user no longer has the ability to change
the bool multipath variable.  We want multipath to be true.

There should be no change in the multipathing policy or code by
enabling or disabling CONFIG_NVME_ENABLE_MULTIPATH_PARAM.

If you want to compile out the mulipath code you should set CONFIG_NVME_ENABLE_MULTIPATH=n.

/John


  reply	other threads:[~2025-03-31 14:29 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-28 19:38 [PATCH v3 0/5] nvme: make core.nvme_multipath configurable John Meneghini
2025-03-28 19:38 ` [PATCH v3 1/5] nvme: update the multipath warning in nvme_init_ns_head John Meneghini
2025-03-28 19:38 ` [PATCH v3 2/5] nvme: change the NVME_MULTIPATH config option description John Meneghini
2025-03-28 19:38 ` [PATCH v3 3/5] nvme: add the NVME_ENABLE_MULTIPATH_PARAM config option John Meneghini
2025-03-28 19:49   ` Caleb Sander Mateos
2025-03-31 14:28     ` John Meneghini [this message]
2025-03-31 23:55       ` Caleb Sander Mateos
2025-03-28 19:38 ` [PATCH v3 4/5] nvme: add NVME_ENABLE_MULTIPATH_PARAM for loongarch John Meneghini
2025-03-28 19:38 ` [PATCH v3 5/5] nvme: add NVME_ENABLE_MULTIPATH_PARAM for powerpc skiroot John Meneghini

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=e22e3cd8-f792-4f20-9624-76e973cf4940@redhat.com \
    --to=jmeneghi@redhat.com \
    --cc=bgurney@redhat.com \
    --cc=csander@purestorage.com \
    --cc=emilne@redhat.com \
    --cc=hch@lst.de \
    --cc=kbusch@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=loberman@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®