[PATCH 0/4] nvme patches for 6.3

Keith Busch kbusch at kernel.org
Fri Feb 10 09:14:49 PST 2023


On Fri, Feb 10, 2023 at 05:29:31PM +0100, Niklas Schnelle wrote:
> So if I understand things correctly possibly thanks to "nvme-pci: use
> mapped entries for sgl decision" a collapsed DMA mapping lands us in
> the entries == 1 case in nvme_pci_setup_sgls() so no extra mapping is
> needed and thus the dma_unmap_sgtable() is the only unmapping we need
> in nvme_unmap_data()? Does that mean that previously this case might
> have used prps and thus now needs fewer mapping operations?

Yes, exactly. The older code could have still decided on using sgls, but it's
definitely more likely with the newer code. This does reduce the memory
allocations so it should be more optimal.

The older code did account for this use_sgl nr_allocations=-1 correctly though,
and I messed that part up when changing it.

> Either way, feel free to add my:
> 
> Tested-by: Niklas Schnelle <schnelle at linux.ibm.com>

Thanks, I'll send a formal patch today.



More information about the Linux-nvme mailing list