Lines Matching refs:ibqp

426 	struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device);  in rvt_free_qp_cb()
429 rvt_reset_qp(rdi, qp, qp->ibqp.qp_type); in rvt_free_qp_cb()
582 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_clear_mr_refs()
666 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_qp_acks_has_lkey()
692 if (qp->ibqp.qp_type == IB_QPT_SMI || in rvt_qp_mr_clean()
693 qp->ibqp.qp_type == IB_QPT_GSI) in rvt_qp_mr_clean()
714 ev.device = qp->ibqp.device; in rvt_qp_mr_clean()
715 ev.element.qp = &qp->ibqp; in rvt_qp_mr_clean()
717 qp->ibqp.event_handler(&ev, qp->ibqp.qp_context); in rvt_qp_mr_clean()
732 u32 n = hash_32(qp->ibqp.qp_num, rdi->qp_dev->qp_table_bits); in rvt_remove_qp()
1029 int rvt_create_qp(struct ib_qp *ibqp, struct ib_qp_init_attr *init_attr, in rvt_create_qp() argument
1032 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_create_qp()
1037 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_create_qp()
1072 init_attr->port_num > ibqp->device->phys_port_cnt) in rvt_create_qp()
1172 qp->ibqp.qp_num = ret; in rvt_create_qp()
1174 qp->ibqp.qp_num |= RVT_AIP_QP_BASE; in rvt_create_qp()
1257 rvt_free_qpn(&rdi->qp_dev->qpn_table, qp->ibqp.qp_num); in rvt_create_qp()
1290 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_error_qp()
1316 wc.qp = &qp->ibqp; in rvt_error_qp()
1322 rvt_cq_enter(ibcq_to_rvtcq(qp->ibqp.recv_cq), &wc, 1); in rvt_error_qp()
1352 rvt_cq_enter(ibcq_to_rvtcq(qp->ibqp.recv_cq), &wc, 1); in rvt_error_qp()
1359 } else if (qp->ibqp.event_handler) { in rvt_error_qp()
1380 if (qp->ibqp.qp_num <= 1) { in rvt_insert_qp()
1381 rcu_assign_pointer(rvp->qp[qp->ibqp.qp_num], qp); in rvt_insert_qp()
1383 u32 n = hash_32(qp->ibqp.qp_num, rdi->qp_dev->qp_table_bits); in rvt_insert_qp()
1402 int rvt_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, in rvt_modify_qp() argument
1405 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_modify_qp()
1406 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_modify_qp()
1424 opa_ah = rdma_cap_opa_ah(ibqp->device, qp->port_num); in rvt_modify_qp()
1426 if (!ib_modify_qp_is_ok(cur_state, new_state, ibqp->qp_type, in rvt_modify_qp()
1445 if (rvt_check_ah(qp->ibqp.device, &attr->ah_attr)) in rvt_modify_qp()
1460 if (rvt_check_ah(qp->ibqp.device, &attr->alt_ah_attr)) in rvt_modify_qp()
1475 if (qp->ibqp.qp_type == IB_QPT_SMI || in rvt_modify_qp()
1476 qp->ibqp.qp_type == IB_QPT_GSI || in rvt_modify_qp()
1478 attr->port_num > ibqp->device->phys_port_cnt) in rvt_modify_qp()
1532 _rvt_reset_qp(rdi, qp, ibqp->qp_type); in rvt_modify_qp()
1547 if (qp->ibqp.qp_type == IB_QPT_RC) in rvt_modify_qp()
1647 ev.device = qp->ibqp.device; in rvt_modify_qp()
1648 ev.element.qp = &qp->ibqp; in rvt_modify_qp()
1650 qp->ibqp.event_handler(&ev, qp->ibqp.qp_context); in rvt_modify_qp()
1653 ev.device = qp->ibqp.device; in rvt_modify_qp()
1654 ev.element.qp = &qp->ibqp; in rvt_modify_qp()
1656 qp->ibqp.event_handler(&ev, qp->ibqp.qp_context); in rvt_modify_qp()
1677 int rvt_destroy_qp(struct ib_qp *ibqp, struct ib_udata *udata) in rvt_destroy_qp() argument
1679 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_destroy_qp()
1680 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_destroy_qp()
1682 rvt_reset_qp(rdi, qp, ibqp->qp_type); in rvt_destroy_qp()
1686 rvt_free_qpn(&rdi->qp_dev->qpn_table, qp->ibqp.qp_num); in rvt_destroy_qp()
1690 if (qp->ibqp.qp_type == IB_QPT_RC) { in rvt_destroy_qp()
1718 int rvt_query_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, in rvt_query_qp() argument
1721 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_query_qp()
1722 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_query_qp()
1735 attr->cap.max_recv_wr = qp->ibqp.srq ? 0 : qp->r_rq.size - 1; in rvt_query_qp()
1756 init_attr->event_handler = qp->ibqp.event_handler; in rvt_query_qp()
1757 init_attr->qp_context = qp->ibqp.qp_context; in rvt_query_qp()
1758 init_attr->send_cq = qp->ibqp.send_cq; in rvt_query_qp()
1759 init_attr->recv_cq = qp->ibqp.recv_cq; in rvt_query_qp()
1760 init_attr->srq = qp->ibqp.srq; in rvt_query_qp()
1766 init_attr->qp_type = qp->ibqp.qp_type; in rvt_query_qp()
1781 int rvt_post_recv(struct ib_qp *ibqp, const struct ib_recv_wr *wr, in rvt_post_recv() argument
1784 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_post_recv()
1788 !qp->ibqp.srq; in rvt_post_recv()
1819 wc.qp = &qp->ibqp; in rvt_post_recv()
1823 rvt_cq_enter(ibcq_to_rvtcq(qp->ibqp.recv_cq), &wc, 1); in rvt_post_recv()
1871 if (!(post_parms[wr->opcode].qpt_support & BIT(qp->ibqp.qp_type))) in rvt_qp_valid_operation()
1874 ibpd_to_rvtpd(qp->ibqp.pd)->user) in rvt_qp_valid_operation()
1886 if (qp->ibqp.qp_type != IB_QPT_UC && in rvt_qp_valid_operation()
1887 qp->ibqp.qp_type != IB_QPT_RC) { in rvt_qp_valid_operation()
1888 if (qp->ibqp.pd != ud_wr(wr)->ah->pd) in rvt_qp_valid_operation()
1948 qp->ibqp.qp_num, qp->s_size, qp->s_avail, in rvt_qp_is_avail()
1971 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_post_one_wr()
2037 pd = ibpd_to_rvtpd(qp->ibqp.pd); in rvt_post_one_wr()
2143 int rvt_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr, in rvt_post_send() argument
2146 struct rvt_qp *qp = ibqp_to_rvtqp(ibqp); in rvt_post_send()
2147 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_post_send()
2274 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in init_sge()
2277 pd = ibpd_to_rvtpd(qp->ibqp.srq ? qp->ibqp.srq->pd : qp->ibqp.pd); in init_sge()
2308 wc.qp = &qp->ibqp; in init_sge()
2310 rvt_cq_enter(ibcq_to_rvtcq(qp->ibqp.recv_cq), &wc, 1); in init_sge()
2357 if (qp->ibqp.srq) { in rvt_get_rwqe()
2358 srq = ibsrq_to_rvtsrq(qp->ibqp.srq); in rvt_get_rwqe()
2431 ev.device = qp->ibqp.device; in rvt_get_rwqe()
2432 ev.element.srq = qp->ibqp.srq; in rvt_get_rwqe()
2453 if (qp->ibqp.event_handler) { in rvt_comm_est()
2456 ev.device = qp->ibqp.device; in rvt_comm_est()
2457 ev.element.qp = &qp->ibqp; in rvt_comm_est()
2459 qp->ibqp.event_handler(&ev, qp->ibqp.qp_context); in rvt_comm_est()
2476 ev.device = qp->ibqp.device; in rvt_rc_error()
2477 ev.element.qp = &qp->ibqp; in rvt_rc_error()
2479 qp->ibqp.event_handler(&ev, qp->ibqp.qp_context); in rvt_rc_error()
2509 struct ib_qp *ibqp = &qp->ibqp; in rvt_add_retry_timer_ext() local
2510 struct rvt_dev_info *rdi = ib_to_rvt(ibqp->device); in rvt_add_retry_timer_ext()
2590 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_rc_timeout()
2618 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_rc_rnr_retry()
2786 rdi = ib_to_rvt(qp->ibqp.device); in rvt_send_complete()
2820 struct rvt_dev_info *rdi = ib_to_rvt(qp->ibqp.device); in rvt_copy_sge()
2888 return sqp->ibqp.qp_type == IB_QPT_RC ? in loopback_qp_drop()
2905 struct rvt_dev_info *rdi = ib_to_rvt(sqp->ibqp.device); in rvt_ruc_loopback()
2927 qp = rvt_lookup_qpn(ib_to_rvt(sqp->ibqp.device), rvp, in rvt_ruc_loopback()
2970 qp->ibqp.qp_type != sqp->ibqp.qp_type) { in rvt_ruc_loopback()
3121 wc.qp = &qp->ibqp; in rvt_ruc_loopback()
3146 if (qp->ibqp.qp_type == IB_QPT_UC) in rvt_ruc_loopback()
3174 sqp->ibqp.qp_type == IB_QPT_RC ? in rvt_ruc_loopback()
3194 if (sqp->ibqp.qp_type == IB_QPT_RC) { in rvt_ruc_loopback()
3206 ev.device = sqp->ibqp.device; in rvt_ruc_loopback()
3207 ev.element.qp = &sqp->ibqp; in rvt_ruc_loopback()
3209 sqp->ibqp.event_handler(&ev, sqp->ibqp.qp_context); in rvt_ruc_loopback()