Home
last modified time | relevance | path

Searched refs:prod_idx (Results 1 – 21 of 21) sorted by relevance

/Linux-v5.4/include/linux/qed/
Dqed_chain.h90 u16 prod_idx; member
96 u32 prod_idx; member
189 return p_chain->u.chain16.prod_idx; in qed_chain_get_prod_idx()
207 (u32)p_chain->u.chain16.prod_idx) - in qed_chain_get_elem_left()
210 used -= p_chain->u.chain16.prod_idx / p_chain->elem_per_page - in qed_chain_get_elem_left()
221 (u64)p_chain->u.chain32.prod_idx) - in qed_chain_get_elem_left_u32()
224 used -= p_chain->u.chain32.prod_idx / p_chain->elem_per_page - in qed_chain_get_elem_left_u32()
351 if ((p_chain->u.chain16.prod_idx & in qed_chain_produce()
353 p_prod_idx = &p_chain->u.chain16.prod_idx; in qed_chain_produce()
358 p_chain->u.chain16.prod_idx++; in qed_chain_produce()
[all …]
/Linux-v5.4/drivers/net/ethernet/huawei/hinic/
Dhinic_hw_qp.c54 #define SQ_DB_PI_HI(prod_idx) ((prod_idx) >> SQ_DB_PI_HI_SHIFT) argument
57 #define SQ_DB_PI_LOW(prod_idx) ((prod_idx) & SQ_DB_PI_LOW_MASK) argument
102 pi_start = atomic_read(&wq->prod_idx); in hinic_sq_prepare_ctxt()
159 pi_start = atomic_read(&wq->prod_idx); in hinic_rq_prepare_ctxt()
471 static void sq_prepare_ctrl(struct hinic_sq_ctrl *ctrl, u16 prod_idx, in sq_prepare_ctrl() argument
592 void hinic_sq_prepare_wqe(struct hinic_sq *sq, u16 prod_idx, in hinic_sq_prepare_wqe() argument
598 sq_prepare_ctrl(&sq_wqe->ctrl, prod_idx, nr_sges); in hinic_sq_prepare_wqe()
614 static u32 sq_prepare_db(struct hinic_sq *sq, u16 prod_idx, unsigned int cos) in sq_prepare_db() argument
617 u8 hi_prod_idx = SQ_DB_PI_HI(SQ_MASKED_IDX(sq, prod_idx)); in sq_prepare_db()
634 void hinic_sq_write_db(struct hinic_sq *sq, u16 prod_idx, unsigned int wqe_size, in hinic_sq_write_db() argument
[all …]
Dhinic_hw_qp.h168 void hinic_sq_prepare_wqe(struct hinic_sq *sq, u16 prod_idx,
172 void hinic_sq_write_db(struct hinic_sq *sq, u16 prod_idx, unsigned int wqe_size,
176 unsigned int wqe_size, u16 *prod_idx);
180 void hinic_sq_write_wqe(struct hinic_sq *sq, u16 prod_idx,
198 unsigned int wqe_size, u16 *prod_idx);
200 void hinic_rq_write_wqe(struct hinic_rq *rq, u16 prod_idx,
218 void hinic_rq_prepare_wqe(struct hinic_rq *rq, u16 prod_idx,
221 void hinic_rq_update(struct hinic_rq *rq, u16 prod_idx);
Dhinic_hw_api_cmd.c93 u32 addr, prod_idx; in set_prod_idx() local
96 prod_idx = hinic_hwif_read_reg(hwif, addr); in set_prod_idx()
98 prod_idx = HINIC_API_CMD_PI_CLEAR(prod_idx, IDX); in set_prod_idx()
100 prod_idx |= HINIC_API_CMD_PI_SET(chain->prod_idx, IDX); in set_prod_idx()
102 hinic_hwif_write_reg(hwif, addr, prod_idx); in set_prod_idx()
125 u32 prod_idx; in chain_busy() local
130 prod_idx = chain->prod_idx; in chain_busy()
133 if (chain->cons_idx == MASKED_IDX(chain, prod_idx + 1)) { in chain_busy()
209 cell_ctxt = &chain->cell_ctxt[chain->prod_idx]; in prepare_api_cmd()
257 chain->prod_idx = MASKED_IDX(chain, chain->prod_idx + 1); in cmd_chain_prod_idx_inc()
[all …]
Dhinic_hw_cmdq.c184 enum hinic_mod_type mod, u8 cmd, u16 prod_idx, in cmdq_prepare_wqe_ctrl() argument
209 ctrl->ctrl_info = HINIC_CMDQ_CTRL_SET(prod_idx, PI) | in cmdq_prepare_wqe_ctrl()
253 enum hinic_mod_type mod, u8 cmd, u16 prod_idx) in cmdq_set_lcmd_wqe() argument
270 prod_idx, complete_format, DATA_SGE, in cmdq_set_lcmd_wqe()
281 enum hinic_mod_type mod, u8 cmd, u16 prod_idx) in cmdq_set_direct_wqe() argument
300 cmdq_prepare_wqe_ctrl(wqe, wrapped, ack_type, mod, cmd, prod_idx, in cmdq_set_direct_wqe()
317 enum hinic_cmdq_type cmdq_type, u16 prod_idx) in cmdq_fill_db() argument
319 *db_info = HINIC_CMDQ_DB_INFO_SET(UPPER_8_BITS(prod_idx), HI_PROD_IDX) | in cmdq_fill_db()
326 enum hinic_cmdq_type cmdq_type, u16 prod_idx) in cmdq_set_db() argument
330 cmdq_fill_db(&db_info, cmdq_type, prod_idx); in cmdq_set_db()
[all …]
Dhinic_hw_wq.c388 size = wq->num_q_pages * sizeof(wq->prod_idx); in alloc_wqes_shadow()
565 atomic_set(&wq->prod_idx, 0); in hinic_wq_allocate()
669 atomic_set(&wq[i].prod_idx, 0); in hinic_wqs_cmdq_alloc()
743 u16 *prod_idx) in hinic_get_wqe() argument
748 *prod_idx = MASKED_WQE_IDX(wq, atomic_read(&wq->prod_idx)); in hinic_get_wqe()
757 end_prod_idx = atomic_add_return(num_wqebbs, &wq->prod_idx); in hinic_get_wqe()
769 *prod_idx = curr_prod_idx; in hinic_get_wqe()
774 copy_wqe_to_shadow(wq, shadow_addr, num_wqebbs, *prod_idx); in hinic_get_wqe()
776 wq->shadow_idx[curr_pg] = *prod_idx; in hinic_get_wqe()
780 return WQ_PAGE_ADDR(wq, *prod_idx) + WQE_PAGE_OFF(wq, *prod_idx); in hinic_get_wqe()
[all …]
Dhinic_hw_wq.h45 atomic_t prod_idx; member
97 u16 *prod_idx);
Dhinic_rx.c204 u16 prod_idx; in rx_alloc_pkts() local
223 &prod_idx); in rx_alloc_pkts()
229 hinic_rq_prepare_wqe(rxq->rq, prod_idx, rq_wqe, &sge); in rx_alloc_pkts()
231 hinic_rq_write_wqe(rxq->rq, prod_idx, rq_wqe, skb); in rx_alloc_pkts()
238 hinic_rq_update(rxq->rq, prod_idx); in rx_alloc_pkts()
Dhinic_tx.c465 u16 prod_idx, q_id = skb->queue_mapping; in hinic_xmit_frame() local
503 sq_wqe = hinic_sq_get_wqe(txq->sq, wqe_size, &prod_idx); in hinic_xmit_frame()
510 sq_wqe = hinic_sq_get_wqe(txq->sq, wqe_size, &prod_idx); in hinic_xmit_frame()
527 hinic_sq_prepare_wqe(txq->sq, prod_idx, sq_wqe, txq->sges, nr_sges); in hinic_xmit_frame()
533 hinic_sq_write_wqe(txq->sq, prod_idx, sq_wqe, skb, wqe_size); in hinic_xmit_frame()
538 hinic_sq_write_db(txq->sq, prod_idx, wqe_size, 0); in hinic_xmit_frame()
Dhinic_hw_api_cmd.h176 u32 prod_idx; member
/Linux-v5.4/drivers/scsi/qedi/
Dqedi_debugfs.c142 u16 prod_idx; in qedi_gbl_ctx_show() local
154 prod_idx = (sb->pi_array[QEDI_PROTO_CQ_PROD_IDX] & in qedi_gbl_ctx_show()
156 seq_printf(s, "SB PROD IDX: %d\n", prod_idx); in qedi_gbl_ctx_show()
Dqedi_main.c1202 u16 prod_idx; in qedi_process_completions() local
1209 prod_idx = sb->pi_array[QEDI_PROTO_CQ_PROD_IDX]; in qedi_process_completions()
1211 if (prod_idx >= QEDI_CQ_SIZE) in qedi_process_completions()
1212 prod_idx = prod_idx % QEDI_CQ_SIZE; in qedi_process_completions()
1217 que, prod_idx, que->cq_cons_idx, fp->sb_id); in qedi_process_completions()
1227 while (que->cq_cons_idx != prod_idx) { in qedi_process_completions()
1232 cqe, prod_idx, que->cq_cons_idx); in qedi_process_completions()
1256 u16 prod_idx; in qedi_fp_has_work() local
1261 prod_idx = sb->pi_array[QEDI_PROTO_CQ_PROD_IDX]; in qedi_fp_has_work()
1267 if (prod_idx >= QEDI_CQ_SIZE) in qedi_fp_has_work()
[all …]
/Linux-v5.4/drivers/net/ethernet/qualcomm/emac/
Demac-mac.c907 u32 prod_idx = (rx_q->rfd.produce_idx << rx_q->produce_shift) & in emac_mac_rx_descs_refill() local
910 rx_q->produce_mask, prod_idx); in emac_mac_rx_descs_refill()
1441 u32 prod_idx; in emac_mac_tx_buf_send() local
1474 prod_idx = (tx_q->tpd.produce_idx << tx_q->produce_shift) & in emac_mac_tx_buf_send()
1477 tx_q->produce_mask, prod_idx); in emac_mac_tx_buf_send()
/Linux-v5.4/drivers/scsi/qedf/
Dqedf_main.c2066 u16 prod_idx; in qedf_fp_has_work() local
2075 prod_idx = sb->pi_array[QEDF_FCOE_PARAMS_GL_RQ_PI]; in qedf_fp_has_work()
2077 return (que->cq_prod_idx != prod_idx); in qedf_fp_has_work()
2094 u16 prod_idx; in qedf_process_completions() local
2105 prod_idx = sb->pi_array[QEDF_FCOE_PARAMS_GL_RQ_PI]; in qedf_process_completions()
2111 new_cqes = (prod_idx >= que->cq_prod_idx) ? in qedf_process_completions()
2112 (prod_idx - que->cq_prod_idx) : in qedf_process_completions()
2113 0x10000 - que->cq_prod_idx + prod_idx; in qedf_process_completions()
2116 que->cq_prod_idx = prod_idx; in qedf_process_completions()
/Linux-v5.4/drivers/scsi/bnx2i/
Dbnx2i.h548 u16 prod_idx; member
Dbnx2i_hwi.c250 rq_db->prod_idx = ep->qp.rq_prod_idx; in bnx2i_put_rq_buf()
277 sq_db->prod_idx = ep->qp.sq_prod_idx; in bnx2i_ring_sq_dbell()
/Linux-v5.4/drivers/staging/qlge/
Dqlge_main.c2656 tx_ring_desc = &tx_ring->q[tx_ring->prod_idx]; in qlge_send()
2692 tx_ring->prod_idx++; in qlge_send()
2693 if (tx_ring->prod_idx == tx_ring->wq_len) in qlge_send()
2694 tx_ring->prod_idx = 0; in qlge_send()
2697 ql_write_db_reg_relaxed(tx_ring->prod_idx, tx_ring->prod_idx_db_reg); in qlge_send()
2700 tx_ring->prod_idx, skb->len); in qlge_send()
3274 tx_ring->prod_idx = 0; in ql_start_tx_ring()
Dqlge.h1051 u32 prod_idx; /* 0x00 */ member
1395 u16 prod_idx; /* current value for prod idx */ member
Dqlge_dbg.c1668 pr_err("tx_ring->prod_idx = %d\n", tx_ring->prod_idx); in ql_dump_tx_ring()
/Linux-v5.4/drivers/infiniband/hw/bnxt_re/
Droce_hsi.h949 __le32 prod_idx; member
956 __le32 prod_idx; member
/Linux-v5.4/drivers/net/ethernet/qlogic/qed/
Dqed_ll2.c1713 u16 prod_idx = qed_chain_get_prod_idx(p_tx_chain); in qed_ll2_prepare_tx_packet_set_bd() local
1772 prod_idx, in qed_ll2_prepare_tx_packet_set_bd()