From: "Maurizio Lombardi" <mlombard@arkamax.eu>
To: "Ramón Jesús Miranda" <ramonjesusmiranda@gmail.com>,
"Keith Busch" <kbusch@kernel.org>, "Jens Axboe" <axboe@kernel.dk>,
"Christoph Hellwig" <hch@lst.de>,
"Sagi Grimberg" <sagi@grimberg.me>
Cc: <linux-nvme@lists.infradead.org>, <linux-kernel@vger.kernel.org>
Subject: Re: nvme-pci: nvme.quirks= on the kernel command line hangs early boot when nvme-pci is built in
Date: Mon, 19 Oct 2026 12:33:32 +0200 [thread overview]
Message-ID: <DM8QWISGYBCZ.FC52WMOJDZDF@arkamax.eu> (raw)
In-Reply-To: <20261018155426.1299676-1-ramonjesusmiranda@gmail.com>
On Sun Oct 18, 2026 at 5:54 PM CEST, Ramón Jesús Miranda wrote:
> Hi,
>
> Passing nvme.quirks=VID:DID:QUIRKS on the kernel command line with
> CONFIG_BLK_DEV_NVME=y hangs the kernel immediately, before any console
> output, on arm64 (Microsoft Surface Pro 11, X1E80100, 7.2.8).
>
> As far as I can tell, quirks_param_set() runs during parse_args() for
> built-in modules, i.e. before memory management is initialised, and it
> allocates there. As a module (nvme.quirks= handled at module load) it
> works.
>
> Removing the parameter boots normally. I have not checked other
> architectures.
>
Hello, USB also allocates memory in that callback... but there is
a small difference...
Could you please test the following patch? (Compile-tested only)
diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c
index 77317e5d00f9..6699c7da4b5a 100644
--- a/drivers/nvme/host/pci.c
+++ b/drivers/nvme/host/pci.c
@@ -243,7 +243,7 @@ static struct kparam_string quirks_param_string = {
.string = quirks_param,
};
-module_param_cb(quirks, &quirks_param_ops, &quirks_param_string, 0444);
+device_param_cb(quirks, &quirks_param_ops, &quirks_param_string, 0444);
MODULE_PARM_DESC(quirks, "Enable/disable NVMe quirks by specifying "
"quirks=VID:DID:quirk_names");
Thanks,
Maurizio
next prev parent reply other threads:[~2026-10-19 10:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-18 15:54 Ramón Jesús Miranda
2026-10-19 10:33 ` Maurizio Lombardi [this message]
[not found] ` <CAP08=V2Kqo8OFrKe7rEk3+J3W65rS8vKpA5a_PBC8qwxvQaKGg@mail.gmail.com>
2026-10-19 15:59 ` Maurizio Lombardi
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=DM8QWISGYBCZ.FC52WMOJDZDF@arkamax.eu \
--to=mlombard@arkamax.eu \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=kbusch@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=ramonjesusmiranda@gmail.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®