Lines Matching refs:ibqp

260 	event.element.qp  = &qp->ibqp;  in mthca_qp_event()
261 if (qp->ibqp.event_handler) in mthca_qp_event()
262 qp->ibqp.event_handler(&event, qp->ibqp.qp_context); in mthca_qp_event()
429 int mthca_query_qp(struct ib_qp *ibqp, struct ib_qp_attr *qp_attr, int qp_attr_mask, in mthca_query_qp() argument
432 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_query_qp()
433 struct mthca_qp *qp = to_mqp(ibqp); in mthca_query_qp()
555 static int __mthca_modify_qp(struct ib_qp *ibqp, in __mthca_modify_qp() argument
559 struct mthca_dev *dev = to_mdev(ibqp->device); in __mthca_modify_qp()
560 struct mthca_qp *qp = to_mqp(ibqp); in __mthca_modify_qp()
621 if (qp->ibqp.uobject) in __mthca_modify_qp()
623 cpu_to_be32(to_mucontext(qp->ibqp.uobject->context)->uar.index); in __mthca_modify_qp()
663 if (ibqp->qp_type == IB_QPT_RC && in __mthca_modify_qp()
665 u8 sched_queue = ibqp->uobject ? 0x2 : 0x1; in __mthca_modify_qp()
705 qp_context->pd = cpu_to_be32(to_mpd(ibqp->pd)->pd_num); in __mthca_modify_qp()
731 qp_context->cqn_snd = cpu_to_be32(to_mcq(ibqp->send_cq)->cqn); in __mthca_modify_qp()
755 if (ibqp->srq) in __mthca_modify_qp()
770 qp_context->cqn_rcv = cpu_to_be32(to_mcq(ibqp->recv_cq)->cqn); in __mthca_modify_qp()
780 if (ibqp->srq) in __mthca_modify_qp()
782 to_msrq(ibqp->srq)->srqn); in __mthca_modify_qp()
830 if (new_state == IB_QPS_RESET && !qp->ibqp.uobject) { in __mthca_modify_qp()
831 mthca_cq_clean(dev, to_mcq(qp->ibqp.recv_cq), qp->qpn, in __mthca_modify_qp()
832 qp->ibqp.srq ? to_msrq(qp->ibqp.srq) : NULL); in __mthca_modify_qp()
833 if (qp->ibqp.send_cq != qp->ibqp.recv_cq) in __mthca_modify_qp()
834 mthca_cq_clean(dev, to_mcq(qp->ibqp.send_cq), qp->qpn, NULL); in __mthca_modify_qp()
854 int mthca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask, in mthca_modify_qp() argument
857 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_modify_qp()
858 struct mthca_qp *qp = to_mqp(ibqp); in mthca_modify_qp()
875 if (!ib_modify_qp_is_ok(cur_state, new_state, ibqp->qp_type, attr_mask, in mthca_modify_qp()
916 err = __mthca_modify_qp(ibqp, attr, attr_mask, cur_state, new_state); in mthca_modify_qp()
1439 send_cq = to_mcq(qp->ibqp.send_cq); in mthca_free_qp()
1440 recv_cq = to_mcq(qp->ibqp.recv_cq); in mthca_free_qp()
1467 if (!qp->ibqp.uobject) { in mthca_free_qp()
1469 qp->ibqp.srq ? to_msrq(qp->ibqp.srq) : NULL); in mthca_free_qp()
1480 atomic_dec(&(to_mpd(qp->ibqp.pd)->sqp_count)); in mthca_free_qp()
1507 mlx->flags |= cpu_to_be32((!sqp->qp.ibqp.qp_num ? MTHCA_MLX_VL15 : 0) | in build_mlx_header()
1528 sqp->ud_header.lrh.virtual_lane = !sqp->qp.ibqp.qp_num ? 15 : 0; in build_mlx_header()
1532 if (!sqp->qp.ibqp.qp_num) in build_mlx_header()
1543 sqp->ud_header.deth.source_qpn = cpu_to_be32(sqp->qp.ibqp.qp_num); in build_mlx_header()
1550 data->lkey = cpu_to_be32(to_mpd(sqp->qp.ibqp.pd)->ntmr.ibmr.lkey); in build_mlx_header()
1614 int mthca_tavor_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr, in mthca_tavor_post_send() argument
1617 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_tavor_post_send()
1618 struct mthca_qp *qp = to_mqp(ibqp); in mthca_tavor_post_send()
1645 if (mthca_wq_overflow(&qp->sq, nreq, qp->ibqp.send_cq)) { in mthca_tavor_post_send()
1817 int mthca_tavor_post_receive(struct ib_qp *ibqp, const struct ib_recv_wr *wr, in mthca_tavor_post_receive() argument
1820 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_tavor_post_receive()
1821 struct mthca_qp *qp = to_mqp(ibqp); in mthca_tavor_post_receive()
1846 if (mthca_wq_overflow(&qp->rq, nreq, qp->ibqp.recv_cq)) { in mthca_tavor_post_receive()
1928 int mthca_arbel_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr, in mthca_arbel_post_send() argument
1931 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_arbel_post_send()
1932 struct mthca_qp *qp = to_mqp(ibqp); in mthca_arbel_post_send()
1986 if (mthca_wq_overflow(&qp->sq, nreq, qp->ibqp.send_cq)) { in mthca_arbel_post_send()
2168 int mthca_arbel_post_receive(struct ib_qp *ibqp, const struct ib_recv_wr *wr, in mthca_arbel_post_receive() argument
2171 struct mthca_dev *dev = to_mdev(ibqp->device); in mthca_arbel_post_receive()
2172 struct mthca_qp *qp = to_mqp(ibqp); in mthca_arbel_post_receive()
2187 if (mthca_wq_overflow(&qp->rq, nreq, qp->ibqp.recv_cq)) { in mthca_arbel_post_receive()
2248 if (qp->ibqp.srq && !is_send) { in mthca_free_err_wqe()