]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
RDMA/core: Add umem "is_contiguous" and "start_dma_addr" helpers
authorMichael Margolin <mrgolin@amazon.com>
Tue, 8 Jul 2025 20:23:07 +0000 (20:23 +0000)
committerLeon Romanovsky <leon@kernel.org>
Sun, 13 Jul 2025 08:00:34 +0000 (04:00 -0400)
commitc897c2c8b8e82981df10df546c753ac857612937
tree09d30b89d25b66e54c00bc70ebeab23d44d57c66
parent1a40c362ae265ca4004f7373b34c22af6810f6cb
RDMA/core: Add umem "is_contiguous" and "start_dma_addr" helpers

In some cases drivers may need to check if a given umem is contiguous.
Add a helper function in core code so that drivers don't need to deal
with umem or scatter-gather lists structure.
Additionally add a helper for getting umem's start DMA address and use
it in other helper functions that open code it.

Signed-off-by: Michael Margolin <mrgolin@amazon.com>
Link: https://patch.msgid.link/20250708202308.24783-3-mrgolin@amazon.com
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
include/rdma/ib_umem.h