[PATCH] nvme-pci: don't use dma_alloc_noncontiguous with 0 merge boundary
Leon Romanovsky
leon at kernel.org
Wed Dec 4 00:55:41 PST 2024
On Wed, Dec 04, 2024 at 09:42:40AM +0900, Christoph Hellwig wrote:
> Only call into nvme_alloc_host_mem_single which uses
> dma_alloc_noncontiguous when there is non-null dma merge boundary.
> Without this we'll call into dma_alloc_noncontiguous for device using
> dma-direct, which can work fine as long as the preferred size is below the
> MAX_ORDER of the page allocator, but blows up with a warning if it is
> too large.
>
> Fixes: 63a5c7a4b4c4 ("nvme-pci: use dma_alloc_noncontigous if possible")
> Reported-by: Leon Romanovsky <leon at kernel.org>
> Reported-by: Chaitanya Kumar Borah <chaitanya.kumar.borah at intel.com>
> Signed-off-by: Christoph Hellwig <hch at lst.de>
> ---
> drivers/nvme/host/pci.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
Except moundary vs. boundary, everything looks good.
Thanks for the fix.
Reviewed-by: Leon Romanovsky <leon at kernel.org>
More information about the Linux-nvme
mailing list