Searched refs:hr_qp (Results 1 – 5 of 5) sorted by relevance
/openbmc/linux/drivers/infiniband/hw/hns/ |
H A D | hns_roce_qp.c | 65 struct hns_roce_qp *hr_qp = container_of(flush_work, in flush_work_handle() local 75 if (test_and_clear_bit(HNS_ROCE_FLUSH_FLAG, &hr_qp->flush_flag)) { in flush_work_handle() 76 ret = hns_roce_modify_qp(&hr_qp->ibqp, &attr, attr_mask, NULL); in flush_work_handle() 86 if (refcount_dec_and_test(&hr_qp->refcount)) in flush_work_handle() 87 complete(&hr_qp->free); in flush_work_handle() 90 void init_flush_work(struct hns_roce_dev *hr_dev, struct hns_roce_qp *hr_qp) in init_flush_work() argument 92 struct hns_roce_work *flush_work = &hr_qp->flush_work; in init_flush_work() 96 refcount_inc(&hr_qp->refcount); in init_flush_work() 144 static void hns_roce_ib_qp_event(struct hns_roce_qp *hr_qp, in hns_roce_ib_qp_event() argument 147 struct ib_qp *ibqp = &hr_qp->ibqp; in hns_roce_ib_qp_event() [all …]
|
H A D | hns_roce_restrack.c | 64 struct hns_roce_qp *hr_qp = to_hr_qp(ib_qp); in hns_roce_fill_res_qp_entry() local 71 if (rdma_nl_put_driver_u32_hex(msg, "sq_wqe_cnt", hr_qp->sq.wqe_cnt)) in hns_roce_fill_res_qp_entry() 74 if (rdma_nl_put_driver_u32_hex(msg, "sq_max_gs", hr_qp->sq.max_gs)) in hns_roce_fill_res_qp_entry() 77 if (rdma_nl_put_driver_u32_hex(msg, "rq_wqe_cnt", hr_qp->rq.wqe_cnt)) in hns_roce_fill_res_qp_entry() 80 if (rdma_nl_put_driver_u32_hex(msg, "rq_max_gs", hr_qp->rq.max_gs)) in hns_roce_fill_res_qp_entry() 83 if (rdma_nl_put_driver_u32_hex(msg, "ext_sge_sge_cnt", hr_qp->sge.sge_cnt)) in hns_roce_fill_res_qp_entry() 99 struct hns_roce_qp *hr_qp = to_hr_qp(ib_qp); in hns_roce_fill_res_qp_entry_raw() local 106 ret = hr_dev->hw->query_qpc(hr_dev, hr_qp->qpn, &context); in hns_roce_fill_res_qp_entry_raw()
|
H A D | hns_roce_hw_v2.c | 373 struct hns_roce_qp *hr_qp) in check_send_valid() argument 375 if (unlikely(hr_qp->state == IB_QPS_RESET || in check_send_valid() 376 hr_qp->state == IB_QPS_INIT || in check_send_valid() 377 hr_qp->state == IB_QPS_RTR)) in check_send_valid() 768 struct hns_roce_qp *hr_qp) in check_recv_valid() argument 773 if (hr_qp->state == IB_QPS_RESET) in check_recv_valid() 806 static void fill_rq_wqe(struct hns_roce_qp *hr_qp, const struct ib_recv_wr *wr, in fill_rq_wqe() argument 811 wqe = hns_roce_get_recv_wqe(hr_qp, wqe_idx); in fill_rq_wqe() 812 fill_recv_sge_to_wqe(wr, wqe, max_sge, hr_qp->rq.rsv_sge); in fill_rq_wqe() 820 struct hns_roce_qp *hr_qp = to_hr_qp(ibqp); in hns_roce_v2_post_recv() local [all …]
|
H A D | hns_roce_main.c | 984 struct hns_roce_qp *hr_qp; in hns_roce_handle_device_err() local 993 list_for_each_entry(hr_qp, &hr_dev->qp_list, node) { in hns_roce_handle_device_err() 994 spin_lock_irqsave(&hr_qp->sq.lock, flags_qp); in hns_roce_handle_device_err() 995 if (hr_qp->sq.tail != hr_qp->sq.head) in hns_roce_handle_device_err() 996 check_and_get_armed_cq(&cq_list, hr_qp->ibqp.send_cq); in hns_roce_handle_device_err() 997 spin_unlock_irqrestore(&hr_qp->sq.lock, flags_qp); in hns_roce_handle_device_err() 999 spin_lock_irqsave(&hr_qp->rq.lock, flags_qp); in hns_roce_handle_device_err() 1000 if ((!hr_qp->ibqp.srq) && (hr_qp->rq.tail != hr_qp->rq.head)) in hns_roce_handle_device_err() 1001 check_and_get_armed_cq(&cq_list, hr_qp->ibqp.recv_cq); in hns_roce_handle_device_err() 1002 spin_unlock_irqrestore(&hr_qp->rq.lock, flags_qp); in hns_roce_handle_device_err()
|
H A D | hns_roce_device.h | 909 struct hns_roce_qp *hr_qp); 1211 void init_flush_work(struct hns_roce_dev *hr_dev, struct hns_roce_qp *hr_qp); 1212 void *hns_roce_get_recv_wqe(struct hns_roce_qp *hr_qp, unsigned int n); 1213 void *hns_roce_get_send_wqe(struct hns_roce_qp *hr_qp, unsigned int n); 1214 void *hns_roce_get_extend_sge(struct hns_roce_qp *hr_qp, unsigned int n); 1221 void hns_roce_qp_remove(struct hns_roce_dev *hr_dev, struct hns_roce_qp *hr_qp); 1222 void hns_roce_qp_destroy(struct hns_roce_dev *hr_dev, struct hns_roce_qp *hr_qp,
|