be pair with rxe_unmap_vaddr
Signed-off-by: Li Zhijian <lizhijian@fujitsu.com>
---
drivers/infiniband/sw/rxe/rxe_loc.h | 2 +-
drivers/infiniband/sw/rxe/rxe_mr.c | 4 ++--
drivers/infiniband/sw/rxe/rxe_resp.c | 4 ++--
3 files changed, 5 insertions(+), 5 deletions(-)
@@ -72,7 +72,7 @@ int rxe_mr_copy(struct rxe_mr *mr, u64 iova, void *addr, int length,
enum rxe_mr_copy_dir dir);
int copy_data(struct rxe_pd *pd, int access, struct rxe_dma_info *dma,
void *addr, int length, enum rxe_mr_copy_dir dir);
-void *iova_to_vaddr(struct rxe_mr *mr, u64 iova, int length);
+void *rxe_map_iova(struct rxe_mr *mr, u64 iova, int length);
void rxe_unmap_vaddr(struct rxe_mr *mr, void *vaddr);
struct rxe_mr *lookup_mr(struct rxe_pd *pd, int access, u32 key,
enum rxe_mr_lookup_type type);
@@ -264,7 +264,7 @@ static void *__iova_to_vaddr(struct rxe_mr *mr, u64 iova, int length)
}
/* must call rxe_unmap_vaddr to unmap vaddr */
-void *iova_to_vaddr(struct rxe_mr *mr, u64 iova, int length)
+void *rxe_map_iova(struct rxe_mr *mr, u64 iova, int length)
{
if (mr->state != RXE_MR_STATE_VALID) {
pr_warn("mr not in valid state\n");
@@ -321,7 +321,7 @@ int rxe_mr_copy(struct rxe_mr *mr, u64 iova, void *addr, int length,
if (bytes > length)
bytes = length;
- va = iova_to_vaddr(mr, iova, bytes);
+ va = rxe_map_iova(mr, iova, bytes);
if (!va)
return -EFAULT;
@@ -615,8 +615,8 @@ static enum resp_states atomic_reply(struct rxe_qp *qp,
goto out;
}
- vaddr = iova_to_vaddr(mr, qp->resp.va + qp->resp.offset,
- sizeof(u64));
+ vaddr = rxe_map_iova(mr, qp->resp.va + qp->resp.offset,
+ sizeof(u64));
/* check vaddr is 8 bytes aligned. */
if (!vaddr || (uintptr_t)vaddr & 7) {