Lines Matching refs:cqp
429 struct irdma_cqp_request *irdma_alloc_and_get_cqp_request(struct irdma_cqp *cqp, in irdma_alloc_and_get_cqp_request() argument
435 spin_lock_irqsave(&cqp->req_lock, flags); in irdma_alloc_and_get_cqp_request()
436 if (!list_empty(&cqp->cqp_avail_reqs)) { in irdma_alloc_and_get_cqp_request()
437 cqp_request = list_first_entry(&cqp->cqp_avail_reqs, in irdma_alloc_and_get_cqp_request()
441 spin_unlock_irqrestore(&cqp->req_lock, flags); in irdma_alloc_and_get_cqp_request()
451 ibdev_dbg(to_ibdev(cqp->sc_cqp.dev), "ERR: CQP Request Fail: No Memory"); in irdma_alloc_and_get_cqp_request()
476 void irdma_free_cqp_request(struct irdma_cqp *cqp, in irdma_free_cqp_request() argument
488 spin_lock_irqsave(&cqp->req_lock, flags); in irdma_free_cqp_request()
489 list_add_tail(&cqp_request->list, &cqp->cqp_avail_reqs); in irdma_free_cqp_request()
490 spin_unlock_irqrestore(&cqp->req_lock, flags); in irdma_free_cqp_request()
492 wake_up(&cqp->remove_wq); in irdma_free_cqp_request()
500 void irdma_put_cqp_request(struct irdma_cqp *cqp, in irdma_put_cqp_request() argument
504 irdma_free_cqp_request(cqp, cqp_request); in irdma_put_cqp_request()
513 irdma_free_pending_cqp_request(struct irdma_cqp *cqp, in irdma_free_pending_cqp_request() argument
521 wait_event_timeout(cqp->remove_wq, in irdma_free_pending_cqp_request()
523 irdma_put_cqp_request(cqp, cqp_request); in irdma_free_pending_cqp_request()
534 struct irdma_cqp *cqp = &rf->cqp; in irdma_cleanup_pending_cqp_op() local
539 pending_work = IRDMA_RING_USED_QUANTA(cqp->sc_cqp.sq_ring); in irdma_cleanup_pending_cqp_op()
540 wqe_idx = IRDMA_RING_CURRENT_TAIL(cqp->sc_cqp.sq_ring); in irdma_cleanup_pending_cqp_op()
543 cqp->scratch_array[wqe_idx]; in irdma_cleanup_pending_cqp_op()
545 irdma_free_pending_cqp_request(cqp, cqp_request); in irdma_cleanup_pending_cqp_op()
546 wqe_idx = (wqe_idx + 1) % IRDMA_RING_SIZE(cqp->sc_cqp.sq_ring); in irdma_cleanup_pending_cqp_op()
554 irdma_free_pending_cqp_request(cqp, cqp_request); in irdma_cleanup_pending_cqp_op()
732 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_handle_cqp_op()
815 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cqp_sds_cmd()
828 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_sds_cmd()
842 struct irdma_sc_cqp *cqp = dev->cqp; in irdma_cqp_qp_suspend_resume() local
847 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, false); in irdma_cqp_qp_suspend_resume()
853 cqp_info->in.u.suspend_resume.cqp = cqp; in irdma_cqp_qp_suspend_resume()
858 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_qp_suspend_resume()
963 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cqp_query_fpm_val_cmd()
969 cqp_info->in.u.query_fpm_val.cqp = dev->cqp; in irdma_cqp_query_fpm_val_cmd()
978 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_query_fpm_val_cmd()
997 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cqp_commit_fpm_val_cmd()
1003 cqp_info->in.u.commit_fpm_val.cqp = dev->cqp; in irdma_cqp_commit_fpm_val_cmd()
1012 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_commit_fpm_val_cmd()
1025 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_cq_create_cmd()
1054 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_qp_create_cmd()
1095 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, false); in irdma_dealloc_push_page()
1106 cqp_info->in.u.manage_push_page.cqp = &rf->cqp.sc_cqp; in irdma_dealloc_push_page()
1111 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_dealloc_push_page()
1154 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cq_wq_destroy()
1165 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cq_wq_destroy()
1199 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, wait); in irdma_hw_modify_qp()
1215 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_hw_modify_qp()
1236 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, in irdma_hw_modify_qp()
1251 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_hw_modify_qp()
1283 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_qp_destroy_cmd()
1301 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_qp_destroy_cmd()
1873 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_gather_stats_cmd()
1888 cqp_info->in.u.stats_gather.cqp = &rf->cqp.sc_cqp; in irdma_cqp_gather_stats_cmd()
1895 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_gather_stats_cmd()
1910 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_stats_inst_cmd()
1928 cqp_info->in.u.stats_manage.cqp = &rf->cqp.sc_cqp; in irdma_cqp_stats_inst_cmd()
1951 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cqp_ceq_cmd()
1962 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_ceq_cmd()
1981 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, true); in irdma_cqp_aeq_cmd()
1992 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_aeq_cmd()
2007 struct irdma_cqp *iwcqp = &rf->cqp; in irdma_cqp_ws_node_cmd()
2008 struct irdma_sc_cqp *cqp = &iwcqp->sc_cqp; in irdma_cqp_ws_node_cmd() local
2028 cqp_info->in.u.ws_node.cqp = cqp; in irdma_cqp_ws_node_cmd()
2037 status = irdma_sc_poll_for_cqp_op_done(cqp, IRDMA_CQP_OP_WORK_SCHED_NODE, in irdma_cqp_ws_node_cmd()
2047 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_cqp_ws_node_cmd()
2075 cqp_request = irdma_alloc_and_get_cqp_request(&rf->cqp, wait); in irdma_ah_cqp_op()
2085 cqp_info->in.u.ah_create.cqp = &rf->cqp.sc_cqp; in irdma_ah_cqp_op()
2089 cqp_info->in.u.ah_destroy.cqp = &rf->cqp.sc_cqp; in irdma_ah_cqp_op()
2097 irdma_put_cqp_request(&rf->cqp, cqp_request); in irdma_ah_cqp_op()