From: Keith Busch <kbusch@kernel.org>
To: Diederik de Haas <didi.debian@cknow.org>
Cc: linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [BUG report] kernel warnings with Samsung 970 EVO 2TB SSD
Date: Mon, 18 Aug 2025 12:58:25 -0600 [thread overview]
Message-ID: <aKN30RVeM3p5NJm1@kbusch-mbp> (raw)
In-Reply-To: <DC3WVB8IOMNV.14F1RIJHNO33Q@cknow.org>
On Sat, Aug 16, 2025 at 04:11:00PM +0200, Diederik de Haas wrote:
> On Sat Aug 16, 2025 at 3:20 PM CEST, Keith Busch wrote:
>
> > If you want to see what the driver is reacting to, you can check the
> > subnqn from command line:
> >
> > # nvme id-ctrl /dev/nvme0 | grep subnqn
> >
> > It'll probably be all zeros. The field has been required by spec, but
> > the driver tolerates ones that don't implement it.
>
> root@nanopi-r5s:~# nvme id-ctrl /dev/nvme0 | grep subnqn
> subnqn :
>
> So it seems to be just empty?
They, it's interpreted as a string. All 0's would be an empty string.
> > It's just a message that the device isn't spec compliant, but
> > otherwise perfectly operational.
>
> But still worthy of a warning (instead of info) msg?
>
> The other kernel warning is this:
>
> nvme nvme0: using unchecked data buffer
>
> The SUBNQN message appears every time, this one appears often, but not
> always.
That one means you've sent a user space passthrough command to a device
that doesn't support SGL DMA. Without that, the nvme protocol uses
implicitly sized DMA that the driver can't be sure is accurate. The user
could theoretically provide a short buffer that can corrupt memory if
done by accident, or be used as an attack vector if done by malicious
software.
This is also not something to worry about unless you run malicious or
buggy software.
> When researching this/these issues, I discovered the nvme-cli package
> (with the nvme command) and via its manpage I found this command:
>
> nvme get-feature /dev/nvme0 -f 3
>
> I didn't even know NVMe's had namespaces, but this didn't look good:
>
> The namespace or the format of that namespace is invalid(0x200b)
>
> ... without actually understanding what it means and/or what its
> consequences are. It could be harmless and/or normal though.
The feature you're requesting is the LBA range, which is namespace
scoped. You need to specify a namespace id, either by opening the
namespace's block device (/dev/nvme0n1) instead of the admin handle
(/dev/nvme0), or you can manually specify the namespace with paramters
"--namespace-id=1" or just "-n1".
next prev parent reply other threads:[~2025-08-18 19:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-16 11:40 [BUG report] kernel warnings with Samsung 970 EVO 2TB SSD Diederik de Haas
2025-08-16 13:20 ` Keith Busch
2025-08-16 14:11 ` Diederik de Haas
2025-08-18 18:58 ` Keith Busch [this message]
2025-08-18 20:48 ` Diederik de Haas
2025-08-18 21:20 ` Diederik de Haas
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=aKN30RVeM3p5NJm1@kbusch-mbp \
--to=kbusch@kernel.org \
--cc=didi.debian@cknow.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
/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.