Lines Matching refs:pi_mr

2664 	struct mlx5_ib_mr *pi_mr = mr->mtt_mr;  in mlx5_ib_map_mtt_mr_sg_pi()  local
2667 pi_mr->mmkey.ndescs = 0; in mlx5_ib_map_mtt_mr_sg_pi()
2668 pi_mr->meta_ndescs = 0; in mlx5_ib_map_mtt_mr_sg_pi()
2669 pi_mr->meta_length = 0; in mlx5_ib_map_mtt_mr_sg_pi()
2671 ib_dma_sync_single_for_cpu(ibmr->device, pi_mr->desc_map, in mlx5_ib_map_mtt_mr_sg_pi()
2672 pi_mr->desc_size * pi_mr->max_descs, in mlx5_ib_map_mtt_mr_sg_pi()
2675 pi_mr->ibmr.page_size = ibmr->page_size; in mlx5_ib_map_mtt_mr_sg_pi()
2676 n = ib_sg_to_pages(&pi_mr->ibmr, data_sg, data_sg_nents, data_sg_offset, in mlx5_ib_map_mtt_mr_sg_pi()
2681 pi_mr->data_iova = pi_mr->ibmr.iova; in mlx5_ib_map_mtt_mr_sg_pi()
2682 pi_mr->data_length = pi_mr->ibmr.length; in mlx5_ib_map_mtt_mr_sg_pi()
2683 pi_mr->ibmr.length = pi_mr->data_length; in mlx5_ib_map_mtt_mr_sg_pi()
2684 ibmr->length = pi_mr->data_length; in mlx5_ib_map_mtt_mr_sg_pi()
2688 u64 iova = pi_mr->data_iova; in mlx5_ib_map_mtt_mr_sg_pi()
2690 n += ib_sg_to_pages(&pi_mr->ibmr, meta_sg, meta_sg_nents, in mlx5_ib_map_mtt_mr_sg_pi()
2693 pi_mr->meta_length = pi_mr->ibmr.length; in mlx5_ib_map_mtt_mr_sg_pi()
2700 pi_mr->pi_iova = (iova & page_mask) + in mlx5_ib_map_mtt_mr_sg_pi()
2701 pi_mr->mmkey.ndescs * ibmr->page_size + in mlx5_ib_map_mtt_mr_sg_pi()
2702 (pi_mr->ibmr.iova & ~page_mask); in mlx5_ib_map_mtt_mr_sg_pi()
2710 pi_mr->ibmr.length = pi_mr->pi_iova + pi_mr->meta_length - iova; in mlx5_ib_map_mtt_mr_sg_pi()
2711 pi_mr->ibmr.iova = iova; in mlx5_ib_map_mtt_mr_sg_pi()
2712 ibmr->length += pi_mr->meta_length; in mlx5_ib_map_mtt_mr_sg_pi()
2715 ib_dma_sync_single_for_device(ibmr->device, pi_mr->desc_map, in mlx5_ib_map_mtt_mr_sg_pi()
2716 pi_mr->desc_size * pi_mr->max_descs, in mlx5_ib_map_mtt_mr_sg_pi()
2729 struct mlx5_ib_mr *pi_mr = mr->klm_mr; in mlx5_ib_map_klm_mr_sg_pi() local
2732 pi_mr->mmkey.ndescs = 0; in mlx5_ib_map_klm_mr_sg_pi()
2733 pi_mr->meta_ndescs = 0; in mlx5_ib_map_klm_mr_sg_pi()
2734 pi_mr->meta_length = 0; in mlx5_ib_map_klm_mr_sg_pi()
2736 ib_dma_sync_single_for_cpu(ibmr->device, pi_mr->desc_map, in mlx5_ib_map_klm_mr_sg_pi()
2737 pi_mr->desc_size * pi_mr->max_descs, in mlx5_ib_map_klm_mr_sg_pi()
2740 n = mlx5_ib_sg_to_klms(pi_mr, data_sg, data_sg_nents, data_sg_offset, in mlx5_ib_map_klm_mr_sg_pi()
2743 ib_dma_sync_single_for_device(ibmr->device, pi_mr->desc_map, in mlx5_ib_map_klm_mr_sg_pi()
2744 pi_mr->desc_size * pi_mr->max_descs, in mlx5_ib_map_klm_mr_sg_pi()
2748 pi_mr->data_iova = 0; in mlx5_ib_map_klm_mr_sg_pi()
2749 pi_mr->ibmr.iova = 0; in mlx5_ib_map_klm_mr_sg_pi()
2750 pi_mr->pi_iova = pi_mr->data_length; in mlx5_ib_map_klm_mr_sg_pi()
2751 ibmr->length = pi_mr->ibmr.length; in mlx5_ib_map_klm_mr_sg_pi()
2762 struct mlx5_ib_mr *pi_mr = NULL; in mlx5_ib_map_mr_sg_pi() local
2791 pi_mr = mr->mtt_mr; in mlx5_ib_map_mr_sg_pi()
2798 pi_mr = mr->klm_mr; in mlx5_ib_map_mr_sg_pi()
2808 mr->pi_mr = pi_mr; in mlx5_ib_map_mr_sg_pi()
2809 if (pi_mr) in mlx5_ib_map_mr_sg_pi()
2810 ibmr->sig_attrs->meta_length = pi_mr->meta_length; in mlx5_ib_map_mr_sg_pi()