]> www.infradead.org Git - users/jedix/linux-maple.git/commit
nvme-pci: don't try to use SGLs for metadata on the admin queue
authorChristoph Hellwig <hch@lst.de>
Sun, 11 May 2025 04:04:27 +0000 (06:04 +0200)
committerChristoph Hellwig <hch@lst.de>
Tue, 20 May 2025 03:34:27 +0000 (05:34 +0200)
commita40c20a605ed48159ea3d9a2bd4532c167995aa3
tree724b31489cb4770127335dd7b7b9c8205729371c
parentd977506f8863807129d7a11f4057dfb1b38085ea
nvme-pci: don't try to use SGLs for metadata on the admin queue

No admin command defined in an NVMe specification supports metadata,
but to protect against vendor specific commands using metadata ensure
that we don't try to use SGLs for metadata on the admin queue, as NVMe
does not support SGLs on the admin queue for the PCI transport.  Do
this by checking if the data transfer has been setup using SGLs as
that is required for using SGLs for metadata.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Keith Busch <kbusch@kernel.org>
Reviewed-by: Leon Romanovsky <leon@kernel.org>
drivers/nvme/host/pci.c