diff options
author | Anumula Murali Mohan Reddy <anumula@chelsio.com> | 2024-07-16 19:55:32 +0530 |
---|---|---|
committer | Leon Romanovsky <leon@kernel.org> | 2024-07-29 11:41:16 +0300 |
commit | 75ab1533d79b046152d424ffe947f79f9d15682c (patch) | |
tree | 7722822a6bc89af6bd6cc2c4ce3bc7416388eb78 /drivers/infiniband/hw/hfi1/device.c | |
parent | 8400291e289ee6b2bf9779ff1c83a291501f017b (diff) | |
download | linux-75ab1533d79b046152d424ffe947f79f9d15682c.tar.gz linux-75ab1533d79b046152d424ffe947f79f9d15682c.tar.bz2 linux-75ab1533d79b046152d424ffe947f79f9d15682c.zip |
RDMA/cxgb4: use dma_mmap_coherent() for mapping non-contiguous memory
dma_alloc_coherent() allocates contiguous memory irrespective of
iommu mode, but after commit f5ff79fddf0e ("dma-mapping: remove CONFIG_DMA_REMAP")
if iommu is enabled in translate mode, dma_alloc_coherent() may
allocate non-contiguous memory. Attempt to map this memory results in panic.
This patch fixes the issue by using dma_mmap_coherent() to map each page
to user space.
Signed-off-by: Anumula Murali Mohan Reddy <anumula@chelsio.com>
Signed-off-by: Potnuri Bharat Teja <bharat@chelsio.com>
Link: https://lore.kernel.org/r/20240716142532.97423-1-anumula@chelsio.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'drivers/infiniband/hw/hfi1/device.c')
0 files changed, 0 insertions, 0 deletions