Home
last modified time | relevance | path

Searched refs:ibmr (Results 1 – 25 of 58) sorted by relevance

123

/linux/net/rds/
H A Dib_frmr.c36 rds_transition_frwr_state(struct rds_ib_mr *ibmr, in rds_transition_frwr_state() argument
40 if (cmpxchg(&ibmr->u.frmr.fr_state, in rds_transition_frwr_state()
47 atomic_dec(&ibmr->ic->i_fastreg_inuse_count); in rds_transition_frwr_state()
57 struct rds_ib_mr *ibmr = NULL; in rds_ib_alloc_frmr() local
66 ibmr = rds_ib_try_reuse_ibmr(pool); in rds_ib_alloc_frmr()
67 if (ibmr) in rds_ib_alloc_frmr()
68 return ibmr; in rds_ib_alloc_frmr()
70 ibmr = kzalloc_node(sizeof(*ibmr), GFP_KERNEL, in rds_ib_alloc_frmr()
72 if (!ibmr) { in rds_ib_alloc_frmr()
77 frmr = &ibmr->u.frmr; in rds_ib_alloc_frmr()
[all …]
/linux/drivers/infiniband/hw/vmw_pvrdma/
H A Dpvrdma_mr.c94 mr->ibmr.lkey = resp->lkey; in pvrdma_get_dma_mr()
95 mr->ibmr.rkey = resp->rkey; in pvrdma_get_dma_mr()
97 return &mr->ibmr; in pvrdma_get_dma_mr()
182 mr->ibmr.lkey = resp->lkey; in pvrdma_reg_user_mr()
183 mr->ibmr.rkey = resp->rkey; in pvrdma_reg_user_mr()
185 return &mr->ibmr; in pvrdma_reg_user_mr()
254 mr->ibmr.lkey = resp->lkey; in pvrdma_alloc_mr()
255 mr->ibmr.rkey = resp->rkey; in pvrdma_alloc_mr()
259 return &mr->ibmr; in pvrdma_alloc_mr()
277 int pvrdma_dereg_mr(struct ib_mr *ibmr, struct ib_udata *udata) in pvrdma_dereg_mr() argument
[all …]
H A Dpvrdma.h141 struct ib_mr ibmr; member
284 static inline struct pvrdma_user_mr *to_vmr(struct ib_mr *ibmr) in to_vmr() argument
286 return container_of(ibmr, struct pvrdma_user_mr, ibmr); in to_vmr()
/linux/drivers/infiniband/hw/mlx5/
H A Dmr.c61 static int __mlx5_ib_dereg_mr(struct ib_mr *ibmr);
1055 mr->ibmr.lkey = mr->mmkey.key; in mlx5_ib_get_dma_mr()
1056 mr->ibmr.rkey = mr->mmkey.key; in mlx5_ib_get_dma_mr()
1059 return &mr->ibmr; in mlx5_ib_get_dma_mr()
1091 mr->ibmr.lkey = mr->mmkey.key; in set_mr_fields()
1092 mr->ibmr.rkey = mr->mmkey.key; in set_mr_fields()
1093 mr->ibmr.length = length; in set_mr_fields()
1094 mr->ibmr.device = &dev->ib_dev; in set_mr_fields()
1095 mr->ibmr.iova = iova; in set_mr_fields()
1151 mr->ibmr.pd = pd; in alloc_cacheable_mr()
[all …]
H A Drestrack.c81 static int fill_stat_mr_entry(struct sk_buff *msg, struct ib_mr *ibmr) in fill_stat_mr_entry() argument
83 struct mlx5_ib_mr *mr = to_mmr(ibmr); in fill_stat_mr_entry()
115 static int fill_res_mr_entry_raw(struct sk_buff *msg, struct ib_mr *ibmr) in fill_res_mr_entry_raw() argument
117 struct mlx5_ib_mr *mr = to_mmr(ibmr); in fill_res_mr_entry_raw()
123 static int fill_res_mr_entry(struct sk_buff *msg, struct ib_mr *ibmr) in fill_res_mr_entry() argument
125 struct mlx5_ib_mr *mr = to_mmr(ibmr); in fill_res_mr_entry()
H A Dodp.c152 pklm->key = cpu_to_be32(mtt->ibmr.lkey); in populate_klm()
220 mlx5_ib_dereg_mr(&mr->ibmr, NULL); in free_implicit_child_mr_work()
463 mr->ibmr.pd = imr->ibmr.pd; in implicit_get_child_mr()
464 mr->ibmr.device = &mr_to_mdev(imr)->ib_dev; in implicit_get_child_mr()
466 mr->ibmr.lkey = mr->mmkey.key; in implicit_get_child_mr()
467 mr->ibmr.rkey = mr->mmkey.key; in implicit_get_child_mr()
468 mr->ibmr.iova = idx * MLX5_IMR_MTT_SIZE; in implicit_get_child_mr()
521 mlx5_ib_dereg_mr(&mr->ibmr, NULL); in implicit_get_child_mr()
599 imr->ibmr.pd = &pd->ibpd; in mlx5_ib_alloc_implicit_mr()
600 imr->ibmr.iova = 0; in mlx5_ib_alloc_implicit_mr()
[all …]
H A Dwr.c198 seg->log2_page_size = ilog2(mr->ibmr.page_size); in set_reg_mkey_seg()
206 seg->start_addr = cpu_to_be64(mr->ibmr.iova); in set_reg_mkey_seg()
207 seg->len = cpu_to_be64(mr->ibmr.length); in set_reg_mkey_seg()
436 data_key = pi_mr->ibmr.lkey; in set_sig_data_segment()
440 prot_key = pi_mr->ibmr.lkey; in set_sig_data_segment()
564 struct ib_sig_attrs *sig_attrs = sig_mr->ibmr.sig_attrs; in set_pi_umr_wr()
576 region_len = pi_mr->ibmr.length; in set_pi_umr_wr()
867 reg_pi_wr.mr = &pi_mr->ibmr; in handle_reg_mr_integrity()
869 reg_pi_wr.key = pi_mr->ibmr.rkey; in handle_reg_mr_integrity()
889 pa_pi_mr.ibmr.lkey = mr->ibmr.pd->local_dma_lkey; in handle_reg_mr_integrity()
[all …]
/linux/drivers/infiniband/sw/rdmavt/
H A Dmr.h12 struct ib_mr ibmr; member
17 static inline struct rvt_mr *to_imr(struct ib_mr *ibmr) in to_imr() argument
19 return container_of(ibmr, struct rvt_mr, ibmr); in to_imr()
30 int rvt_dereg_mr(struct ib_mr *ibmr, struct ib_udata *udata);
33 int rvt_map_mr_sg(struct ib_mr *ibmr, struct scatterlist *sg,
H A Dmr.c259 mr->ibmr.lkey = mr->mr.lkey; in __rvt_alloc_mr()
260 mr->ibmr.rkey = mr->mr.lkey; in __rvt_alloc_mr()
314 ret = &mr->ibmr; in rvt_get_dma_mr()
387 return &mr->ibmr; in rvt_reg_user_mr()
509 int rvt_dereg_mr(struct ib_mr *ibmr, struct ib_udata *udata) in rvt_dereg_mr() argument
511 struct rvt_mr *mr = to_imr(ibmr); in rvt_dereg_mr()
547 return &mr->ibmr; in rvt_alloc_mr()
557 static int rvt_set_page(struct ib_mr *ibmr, u64 addr) in rvt_set_page() argument
559 struct rvt_mr *mr = to_imr(ibmr); in rvt_set_page()
588 int rvt_map_mr_sg(struct ib_mr *ibmr, struct scatterlist *sg, in rvt_map_mr_sg() argument
[all …]
H A Dtrace_mr.h144 TP_PROTO(struct ib_mr *ibmr, int sg_nents, unsigned int *sg_offset),
145 TP_ARGS(ibmr, sg_nents, sg_offset),
147 RDI_DEV_ENTRY(ib_to_rvt(to_imr(ibmr)->mr.pd->device))
156 RDI_DEV_ASSIGN(ib_to_rvt(to_imr(ibmr)->mr.pd->device));
157 __entry->ibmr_iova = ibmr->iova;
158 __entry->iova = to_imr(ibmr)->mr.iova;
159 __entry->user_base = to_imr(ibmr)->mr.user_base;
160 __entry->ibmr_length = to_imr(ibmr)->mr.length;
/linux/drivers/infiniband/sw/rxe/
H A Drxe_mr.c29 switch (mr->ibmr.type) { in mr_check_range()
35 if (iova < mr->ibmr.iova || in mr_check_range()
36 iova + length > mr->ibmr.iova + mr->ibmr.length) { in mr_check_range()
57 mr->lkey = mr->ibmr.lkey = key; in rxe_mr_init()
58 mr->rkey = mr->ibmr.rkey = key; in rxe_mr_init()
61 mr->ibmr.page_size = PAGE_SIZE; in rxe_mr_init()
72 mr->ibmr.type = IB_MR_TYPE_DMA; in rxe_mr_init_dma()
77 return (iova >> mr->page_shift) - (mr->ibmr.iova >> mr->page_shift); in rxe_mr_iova_to_index()
153 mr->ibmr.type = IB_MR_TYPE_USER; in rxe_mr_init_user()
200 mr->ibmr.type = IB_MR_TYPE_MEM_REG; in rxe_mr_init_fast()
[all …]
H A Drxe_verbs.c1239 mr->ibmr.pd = ibpd; in rxe_get_dma_mr()
1240 mr->ibmr.device = ibpd->device; in rxe_get_dma_mr()
1244 return &mr->ibmr; in rxe_get_dma_mr()
1278 mr->ibmr.pd = ibpd; in rxe_reg_user_mr()
1279 mr->ibmr.device = ibpd->device; in rxe_reg_user_mr()
1288 return &mr->ibmr; in rxe_reg_user_mr()
1300 static struct ib_mr *rxe_rereg_user_mr(struct ib_mr *ibmr, int flags, in rxe_rereg_user_mr() argument
1305 struct rxe_mr *mr = to_rmr(ibmr); in rxe_rereg_user_mr()
1306 struct rxe_pd *old_pd = to_rpd(ibmr->pd); in rxe_rereg_user_mr()
1320 mr->ibmr.pd = ibpd; in rxe_rereg_user_mr()
[all …]
H A Drxe_verbs.h303 struct ib_mr ibmr; member
325 return mr ? mr->ibmr.page_size : PAGE_SIZE; in mr_page_size()
451 return mr ? container_of(mr, struct rxe_mr, ibmr) : NULL; in to_rmr()
466 return to_rpd(mr->ibmr.pd); in mr_pd()
H A Drxe_mw.c117 if (unlikely(wqe->wr.wr.mw.length > mr->ibmr.length)) { in rxe_check_bind_mw()
123 if (unlikely((wqe->wr.wr.mw.addr < mr->ibmr.iova) || in rxe_check_bind_mw()
125 (mr->ibmr.iova + mr->ibmr.length)))) { in rxe_check_bind_mw()
H A Drxe.h56 #define rxe_dbg_mr(mr, fmt, ...) ibdev_dbg((mr)->ibmr.device, \
77 #define rxe_err_mr(mr, fmt, ...) ibdev_err_ratelimited((mr)->ibmr.device, \
98 #define rxe_info_mr(mr, fmt, ...) ibdev_info_ratelimited((mr)->ibmr.device, \
/linux/drivers/infiniband/hw/mlx4/
H A Dmr.c76 mr->ibmr.rkey = mr->ibmr.lkey = mr->mmr.key; in mlx4_ib_get_dma_mr()
79 return &mr->ibmr; in mlx4_ib_get_dma_mr()
441 mr->ibmr.rkey = mr->ibmr.lkey = mr->mmr.key; in mlx4_ib_reg_user_mr()
442 mr->ibmr.page_size = 1U << shift; in mlx4_ib_reg_user_mr()
444 return &mr->ibmr; in mlx4_ib_reg_user_mr()
587 struct ib_device *device = mr->ibmr.device; in mlx4_free_priv_pages()
596 int mlx4_ib_dereg_mr(struct ib_mr *ibmr, struct ib_udata *udata) in mlx4_ib_dereg_mr() argument
598 struct mlx4_ib_mr *mr = to_mmr(ibmr); in mlx4_ib_dereg_mr()
603 ret = mlx4_mr_free(to_mdev(ibmr->device)->dev, &mr->mmr); in mlx4_ib_dereg_mr()
673 mr->ibmr.rkey = mr->ibmr.lkey = mr->mmr.key; in mlx4_ib_alloc_mr()
[all …]
/linux/drivers/infiniband/hw/mana/
H A Dmr.c66 mr->ibmr.lkey = resp.lkey; in mana_ib_gd_create_mr()
67 mr->ibmr.rkey = resp.rkey; in mana_ib_gd_create_mr()
159 return &mr->ibmr; in mana_ib_reg_user_mr()
172 int mana_ib_dereg_mr(struct ib_mr *ibmr, struct ib_udata *udata) in mana_ib_dereg_mr() argument
174 struct mana_ib_mr *mr = container_of(ibmr, struct mana_ib_mr, ibmr); in mana_ib_dereg_mr()
175 struct ib_device *ibdev = ibmr->device; in mana_ib_dereg_mr()
/linux/drivers/infiniband/hw/usnic/
H A Dusnic_ib.h69 struct ib_mr ibmr; member
125 struct usnic_ib_mr *to_umr(struct ib_mr *ibmr) in to_umr() argument
127 return container_of(ibmr, struct usnic_ib_mr, ibmr); in to_umr()
/linux/net/sunrpc/xprtrdma/
H A Dfrwr_ops.c293 struct ib_mr *ibmr; in frwr_map() local
319 ibmr = mr->mr_ibmr; in frwr_map()
320 n = ib_map_mr_sg(ibmr, mr->mr_sg, dma_nents, NULL, PAGE_SIZE); in frwr_map()
324 ibmr->iova &= 0x00000000ffffffff; in frwr_map()
325 ibmr->iova |= ((u64)be32_to_cpu(xid)) << 32; in frwr_map()
326 key = (u8)(ibmr->rkey & 0x000000FF); in frwr_map()
327 ib_update_fast_reg_key(ibmr, ++key); in frwr_map()
330 reg_wr->mr = ibmr; in frwr_map()
331 reg_wr->key = ibmr->rkey; in frwr_map()
336 mr->mr_handle = ibmr->rkey; in frwr_map()
[all …]
/linux/drivers/infiniband/hw/cxgb4/
H A Dmem.c384 mhp->ibmr.rkey = mhp->ibmr.lkey = stag; in finish_mem_reg()
385 mhp->ibmr.length = mhp->attr.len; in finish_mem_reg()
386 mhp->ibmr.page_size = 1U << (mhp->attr.page_size + 12); in finish_mem_reg()
478 return &mhp->ibmr; in c4iw_get_dma_mr()
582 return &mhp->ibmr; in c4iw_reg_user_mr()
653 mhp->ibmr.rkey = mhp->ibmr.lkey = stag; in c4iw_alloc_mr()
660 return &(mhp->ibmr); in c4iw_alloc_mr()
678 static int c4iw_set_page(struct ib_mr *ibmr, u64 addr) in c4iw_set_page() argument
680 struct c4iw_mr *mhp = to_c4iw_mr(ibmr); in c4iw_set_page()
690 int c4iw_map_mr_sg(struct ib_mr *ibmr, struct scatterlist *sg, int sg_nents, in c4iw_map_mr_sg() argument
[all …]
/linux/drivers/infiniband/hw/mthca/
H A Dmthca_provider.h74 struct ib_mr ibmr; member
286 static inline struct mthca_mr *to_mmr(struct ib_mr *ibmr) in to_mmr() argument
288 return container_of(ibmr, struct mthca_mr, ibmr); in to_mmr()
/linux/drivers/infiniband/hw/erdma/
H A Derdma_verbs.h125 struct ib_mr ibmr; member
304 static inline struct erdma_mr *to_emr(struct ib_mr *ibmr) in to_emr() argument
306 return container_of(ibmr, struct erdma_mr, ibmr); in to_emr()
352 int erdma_dereg_mr(struct ib_mr *ibmr, struct ib_udata *data);
365 int erdma_map_mr_sg(struct ib_mr *ibmr, struct scatterlist *sg, int sg_nents,
H A Derdma_verbs.c133 struct erdma_pd *pd = to_epd(mr->ibmr.pd); in regmr_cmd()
154 FIELD_PREP(ERDMA_CMD_MR_KEY_MASK, mr->ibmr.lkey & 0xFF) | in regmr_cmd()
155 FIELD_PREP(ERDMA_CMD_MR_MPT_IDX_MASK, mr->ibmr.lkey >> 8); in regmr_cmd()
1051 mr->ibmr.lkey = stag; in erdma_get_dma_mr()
1052 mr->ibmr.rkey = stag; in erdma_get_dma_mr()
1053 mr->ibmr.pd = ibpd; in erdma_get_dma_mr()
1059 return &mr->ibmr; in erdma_get_dma_mr()
1063 mr->ibmr.lkey >> 8); in erdma_get_dma_mr()
1095 mr->ibmr.lkey = stag; in erdma_ib_alloc_mr()
1096 mr->ibmr.rkey = stag; in erdma_ib_alloc_mr()
[all …]
/linux/drivers/infiniband/hw/ocrdma/
H A Docrdma.h192 struct ib_mr ibmr; member
481 static inline struct ocrdma_mr *get_ocrdma_mr(struct ib_mr *ibmr) in get_ocrdma_mr() argument
483 return container_of(ibmr, struct ocrdma_mr, ibmr); in get_ocrdma_mr()
/linux/drivers/infiniband/hw/irdma/
H A Dverbs.c2541 struct irdma_pd *iwpd = to_iwpd(iwmr->ibmr.pd); in irdma_hw_alloc_mw()
2642 struct ib_pd *pd = iwmr->ibmr.pd; in irdma_hw_alloc_stag()
2701 iwmr->ibmr.rkey = stag; in irdma_alloc_mr()
2702 iwmr->ibmr.lkey = stag; in irdma_alloc_mr()
2703 iwmr->ibmr.pd = pd; in irdma_alloc_mr()
2704 iwmr->ibmr.device = pd->device; in irdma_alloc_mr()
2723 return &iwmr->ibmr; in irdma_alloc_mr()
2739 static int irdma_set_page(struct ib_mr *ibmr, u64 addr) in irdma_set_page() argument
2741 struct irdma_mr *iwmr = to_iwmr(ibmr); in irdma_set_page()
2770 static int irdma_map_mr_sg(struct ib_mr *ibmr, struct scatterlist *sg, in irdma_map_mr_sg() argument
[all …]

123