• Home
  • Raw
  • Download

Lines Matching refs:msrq

44 	return mlx4_buf_offset(&srq->buf, n << srq->msrq.wqe_shift);  in get_wqe()
96 srq->msrq.max = roundup_pow_of_two(init_attr->attr.max_wr + 1); in mlx4_ib_create_srq()
97 srq->msrq.max_gs = init_attr->attr.max_sge; in mlx4_ib_create_srq()
101 srq->msrq.max_gs * in mlx4_ib_create_srq()
103 srq->msrq.wqe_shift = ilog2(desc_size); in mlx4_ib_create_srq()
105 buf_size = srq->msrq.max * desc_size; in mlx4_ib_create_srq()
143 srq->tail = srq->msrq.max - 1; in mlx4_ib_create_srq()
146 for (i = 0; i < srq->msrq.max; ++i) { in mlx4_ib_create_srq()
149 cpu_to_be16((i + 1) & (srq->msrq.max - 1)); in mlx4_ib_create_srq()
166 srq->wrid = kvmalloc_array(srq->msrq.max, in mlx4_ib_create_srq()
180 &srq->mtt, srq->db.dma, &srq->msrq); in mlx4_ib_create_srq()
184 srq->msrq.event = mlx4_ib_srq_event; in mlx4_ib_create_srq()
185 srq->ibsrq.ext.xrc.srq_num = srq->msrq.srqn; in mlx4_ib_create_srq()
188 if (ib_copy_to_udata(udata, &srq->msrq.srqn, sizeof (__u32))) { in mlx4_ib_create_srq()
193 init_attr->attr.max_wr = srq->msrq.max - 1; in mlx4_ib_create_srq()
230 if (attr->srq_limit >= srq->msrq.max) in mlx4_ib_modify_srq()
234 ret = mlx4_srq_arm(dev->dev, &srq->msrq, attr->srq_limit); in mlx4_ib_modify_srq()
251 ret = mlx4_srq_query(dev->dev, &srq->msrq, &limit_watermark); in mlx4_ib_query_srq()
256 srq_attr->max_wr = srq->msrq.max - 1; in mlx4_ib_query_srq()
257 srq_attr->max_sge = srq->msrq.max_gs; in mlx4_ib_query_srq()
265 struct mlx4_ib_srq *msrq = to_msrq(srq); in mlx4_ib_destroy_srq() local
267 mlx4_srq_free(dev->dev, &msrq->msrq); in mlx4_ib_destroy_srq()
268 mlx4_mtt_cleanup(dev->dev, &msrq->mtt); in mlx4_ib_destroy_srq()
276 &msrq->db); in mlx4_ib_destroy_srq()
278 kvfree(msrq->wrid); in mlx4_ib_destroy_srq()
279 mlx4_buf_free(dev->dev, msrq->msrq.max << msrq->msrq.wqe_shift, in mlx4_ib_destroy_srq()
280 &msrq->buf); in mlx4_ib_destroy_srq()
281 mlx4_db_free(dev->dev, &msrq->db); in mlx4_ib_destroy_srq()
283 ib_umem_release(msrq->umem); in mlx4_ib_destroy_srq()
321 if (unlikely(wr->num_sge > srq->msrq.max_gs)) { in mlx4_ib_post_srq_recv()
345 if (i < srq->msrq.max_gs) { in mlx4_ib_post_srq_recv()