Lines Matching refs:qidx
18 struct otx2_nic *pfvf, int qidx) in otx2_nix_rq_op_stats() argument
20 u64 incr = (u64)qidx << 32; in otx2_nix_rq_op_stats()
31 struct otx2_nic *pfvf, int qidx) in otx2_nix_sq_op_stats() argument
33 u64 incr = (u64)qidx << 32; in otx2_nix_sq_op_stats()
74 int otx2_update_rq_stats(struct otx2_nic *pfvf, int qidx) in otx2_update_rq_stats() argument
76 struct otx2_rcv_queue *rq = &pfvf->qset.rq[qidx]; in otx2_update_rq_stats()
81 otx2_nix_rq_op_stats(&rq->stats, pfvf, qidx); in otx2_update_rq_stats()
85 int otx2_update_sq_stats(struct otx2_nic *pfvf, int qidx) in otx2_update_sq_stats() argument
87 struct otx2_snd_queue *sq = &pfvf->qset.sq[qidx]; in otx2_update_sq_stats()
92 otx2_nix_sq_op_stats(&sq->stats, pfvf, qidx); in otx2_update_sq_stats()
336 aq->qidx = index + idx; in otx2_set_rss_table()
502 void otx2_config_irq_coalescing(struct otx2_nic *pfvf, int qidx) in otx2_config_irq_coalescing() argument
510 otx2_write64(pfvf, NIX_LF_CINTX_WAIT(qidx), in otx2_config_irq_coalescing()
760 int qidx, sqe_tail, sqe_head; in otx2_sqb_flush() local
765 for (qidx = 0; qidx < pfvf->hw.tot_tx_queues; qidx++) { in otx2_sqb_flush()
766 incr = (u64)qidx << 32; in otx2_sqb_flush()
795 static int otx2_rq_init(struct otx2_nic *pfvf, u16 qidx, u16 lpb_aura) in otx2_rq_init() argument
805 aq->rq.cq = qidx; in otx2_rq_init()
821 aq->qidx = qidx; in otx2_rq_init()
828 int otx2_sq_aq_init(void *dev, u16 qidx, u16 sqb_aura) in otx2_sq_aq_init() argument
834 sq = &pfvf->qset.sq[qidx]; in otx2_sq_aq_init()
835 sq->lmt_addr = (__force u64 *)(pfvf->reg_base + LMT_LF_LMTLINEX(qidx)); in otx2_sq_aq_init()
841 aq->sq.cq = pfvf->hw.rx_queues + qidx; in otx2_sq_aq_init()
845 aq->sq.smq = otx2_get_smq_idx(pfvf, qidx); in otx2_sq_aq_init()
858 aq->qidx = qidx; in otx2_sq_aq_init()
865 static int otx2_sq_init(struct otx2_nic *pfvf, u16 qidx, u16 sqb_aura) in otx2_sq_init() argument
873 sq = &qset->sq[qidx]; in otx2_sq_init()
881 if (qidx < pfvf->hw.tx_queues) { in otx2_sq_init()
893 if (pfvf->ptp && qidx < pfvf->hw.tx_queues) { in otx2_sq_init()
913 return pfvf->hw_ops->sq_aq_init(pfvf, qidx, sqb_aura); in otx2_sq_init()
917 static int otx2_cq_init(struct otx2_nic *pfvf, u16 qidx) in otx2_cq_init() argument
924 cq = &qset->cq[qidx]; in otx2_cq_init()
925 cq->cq_idx = qidx; in otx2_cq_init()
927 if (qidx < pfvf->hw.rx_queues) { in otx2_cq_init()
929 cq->cint_idx = qidx; in otx2_cq_init()
932 xdp_rxq_info_reg(&cq->xdp_rxq, pfvf->netdev, qidx, 0); in otx2_cq_init()
933 } else if (qidx < non_xdp_queues) { in otx2_cq_init()
935 cq->cint_idx = qidx - pfvf->hw.rx_queues; in otx2_cq_init()
939 cq->cint_idx = qidx - non_xdp_queues; in otx2_cq_init()
955 (pfvf->hw.rqpool_cnt != pfvf->hw.rx_queues)) ? 0 : qidx; in otx2_cq_init()
973 if (qidx < pfvf->hw.rx_queues) { in otx2_cq_init()
981 aq->cq.bpid = pfvf->bpid[pfvf->queue_to_pfc_map[qidx]]; in otx2_cq_init()
992 aq->qidx = qidx; in otx2_cq_init()
1004 int qidx, free_ptrs = 0; in otx2_pool_refill_task() local
1010 qidx = wrk - pfvf->refill_wrk; in otx2_pool_refill_task()
1011 cq = &pfvf->qset.cq[qidx]; in otx2_pool_refill_task()
1031 pfvf->hw_ops->aura_freeptr(pfvf, qidx, bufptr + OTX2_HEAD_ROOM); in otx2_pool_refill_task()
1039 int qidx, err; in otx2_config_nix_queues() local
1042 for (qidx = 0; qidx < pfvf->hw.rx_queues; qidx++) { in otx2_config_nix_queues()
1043 u16 lpb_aura = otx2_get_pool_idx(pfvf, AURA_NIX_RQ, qidx); in otx2_config_nix_queues()
1045 err = otx2_rq_init(pfvf, qidx, lpb_aura); in otx2_config_nix_queues()
1051 for (qidx = 0; qidx < pfvf->hw.tot_tx_queues; qidx++) { in otx2_config_nix_queues()
1052 u16 sqb_aura = otx2_get_pool_idx(pfvf, AURA_NIX_SQ, qidx); in otx2_config_nix_queues()
1054 err = otx2_sq_init(pfvf, qidx, sqb_aura); in otx2_config_nix_queues()
1060 for (qidx = 0; qidx < pfvf->qset.cq_cnt; qidx++) { in otx2_config_nix_queues()
1061 err = otx2_cq_init(pfvf, qidx); in otx2_config_nix_queues()
1075 for (qidx = 0; qidx < pfvf->qset.cq_cnt; qidx++) { in otx2_config_nix_queues()
1076 pfvf->refill_wrk[qidx].pf = pfvf; in otx2_config_nix_queues()
1077 INIT_DELAYED_WORK(&pfvf->refill_wrk[qidx].pool_refill_work, in otx2_config_nix_queues()
1133 int sqb, qidx; in otx2_sq_free_sqbs() local
1136 for (qidx = 0; qidx < hw->tot_tx_queues; qidx++) { in otx2_sq_free_sqbs()
1137 sq = &qset->sq[qidx]; in otx2_sq_free_sqbs()
1332 int qidx, pool_id, stack_pages, num_sqbs; in otx2_sq_aura_pool_init() local
1352 for (qidx = 0; qidx < hw->tot_tx_queues; qidx++) { in otx2_sq_aura_pool_init()
1353 pool_id = otx2_get_pool_idx(pfvf, AURA_NIX_SQ, qidx); in otx2_sq_aura_pool_init()
1372 for (qidx = 0; qidx < hw->tot_tx_queues; qidx++) { in otx2_sq_aura_pool_init()
1373 pool_id = otx2_get_pool_idx(pfvf, AURA_NIX_SQ, qidx); in otx2_sq_aura_pool_init()
1376 sq = &qset->sq[qidx]; in otx2_sq_aura_pool_init()
1693 int irq, qidx; in otx2_free_cints() local
1695 for (qidx = 0, irq = hw->nix_msixoff + NIX_LF_CINT_VEC_START; in otx2_free_cints()
1696 qidx < n; in otx2_free_cints()
1697 qidx++, irq++) { in otx2_free_cints()
1702 free_irq(vector, &qset->napi[qidx]); in otx2_free_cints()