nvme-pci: nvme.quirks= on the kernel command line hangs early boot when nvme-pci is built in
Maurizio Lombardi
mlombard at arkamax.eu
Mon Oct 19 08:59:33 PDT 2026
On Mon Oct 19, 2026 at 5:48 PM CEST, Ramón Jesús Miranda Hernández wrote:
> Hi Maurizio,
>
> Thanks for the quick look and the patch. I tested device_param_cb() on the
> Surface Pro 11 (X1E80100) with CONFIG_BLK_DEV_NVME=y: kernel 7.2.8 built
> from 616a9f22 plus your change, booted with the parameter on the command
> line.
>
> Result: with the patch the kernel boots with
> nvme.quirks=0xffff:0xffff:bogus_nid
> It reaches login with no hang, and the parameter is visible afterwards in
> /sys/module/nvme/parameters/quirks. The nvme0 controller probes normally
> (pci 0006:01:00.0, 64 MiB HMB, 12 queues).
>
> Caveat: I used a placeholder VID:DID that matches no device, so this shows
> the parameter is parsed at boot without hanging. It does not show a real
> quirk being applied to a matching controller. I can retry with the VID:DID
> of the Surface's NVMe if that is useful for your review.
Thanks for testing!
It's not necessary to test a real quirk, just be sure the callback gets
called and doesn't hang the kernel.
A useful thing is to re-test if the quirks parameter still works
as before when CONFIG_BLK_DEV_NVME=M, to be sure we are not introducing
a regression.
Maurizio
More information about the Linux-nvme
mailing list