Lines Matching refs:cq
323 struct cmp_queue *cq, int q_len) in nicvf_init_cmp_queue() argument
327 err = nicvf_alloc_q_desc_mem(nic, &cq->dmem, q_len, CMP_QUEUE_DESC_SIZE, in nicvf_init_cmp_queue()
332 cq->desc = cq->dmem.base; in nicvf_init_cmp_queue()
333 cq->thresh = CMP_QUEUE_CQE_THRESH; in nicvf_init_cmp_queue()
339 static void nicvf_free_cmp_queue(struct nicvf *nic, struct cmp_queue *cq) in nicvf_free_cmp_queue() argument
341 if (!cq) in nicvf_free_cmp_queue()
343 if (!cq->dmem.base) in nicvf_free_cmp_queue()
346 nicvf_free_q_desc_mem(nic, &cq->dmem); in nicvf_free_cmp_queue()
563 struct cmp_queue *cq; in nicvf_cmp_queue_config() local
566 cq = &qs->cq[qidx]; in nicvf_cmp_queue_config()
567 cq->enable = enable; in nicvf_cmp_queue_config()
569 if (!cq->enable) { in nicvf_cmp_queue_config()
577 if (!cq->enable) in nicvf_cmp_queue_config()
580 spin_lock_init(&cq->lock); in nicvf_cmp_queue_config()
583 qidx, (u64)(cq->dmem.phys_base)); in nicvf_cmp_queue_config()
595 nicvf_queue_reg_write(nic, NIC_QSET_CQ_0_7_THRESH, qidx, cq->thresh); in nicvf_cmp_queue_config()
735 nicvf_free_cmp_queue(nic, &qs->cq[qidx]); in nicvf_free_resources()
762 if (nicvf_init_cmp_queue(nic, &qs->cq[qidx], qs->cq_len)) in nicvf_alloc_resources()
1418 struct cmp_queue *cq, struct cqe_rx_t *cqe_rx) in nicvf_check_cqe_rx_errs() argument
1514 struct cmp_queue *cq, struct cqe_send_t *cqe_tx) in nicvf_check_cqe_tx_errs() argument
1516 struct cmp_queue_stats *stats = &cq->stats; in nicvf_check_cqe_tx_errs()