MCPcopy Create free account
hub / github.com/F-Stack/f-stack / bnxt_tx_queue_start

Function bnxt_tx_queue_start

dpdk/drivers/net/bnxt/bnxt_txr.c:620–646  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

618}
619
620int bnxt_tx_queue_start(struct rte_eth_dev *dev, uint16_t tx_queue_id)
621{
622 struct bnxt *bp = dev->data->dev_private;
623 struct bnxt_tx_queue *txq = bp->tx_queues[tx_queue_id];
624 int rc = 0;
625
626 rc = is_bnxt_in_error(bp);
627 if (rc)
628 return rc;
629
630 /* reset the previous stats for the tx_queue since the counters
631 * will be cleared when the queue is started.
632 */
633 memset(&bp->prev_tx_ring_stats[tx_queue_id], 0,
634 sizeof(struct bnxt_ring_stats));
635
636 bnxt_free_hwrm_tx_ring(bp, tx_queue_id);
637 rc = bnxt_alloc_hwrm_tx_ring(bp, tx_queue_id);
638 if (rc)
639 return rc;
640
641 dev->data->tx_queue_state[tx_queue_id] = RTE_ETH_QUEUE_STATE_STARTED;
642 txq->tx_started = true;
643 PMD_DRV_LOG(DEBUG, "Tx queue started\n");
644
645 return 0;
646}
647
648int bnxt_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
649{

Callers

nothing calls this directly

Calls 4

is_bnxt_in_errorFunction · 0.85
memsetFunction · 0.85
bnxt_free_hwrm_tx_ringFunction · 0.85
bnxt_alloc_hwrm_tx_ringFunction · 0.85

Tested by

no test coverage detected