aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/thunderx/nicvf_ethdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/thunderx/nicvf_ethdev.c')
-rw-r--r--drivers/net/thunderx/nicvf_ethdev.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/thunderx/nicvf_ethdev.c b/drivers/net/thunderx/nicvf_ethdev.c
index c62371cb..3843084b 100644
--- a/drivers/net/thunderx/nicvf_ethdev.c
+++ b/drivers/net/thunderx/nicvf_ethdev.c
@@ -897,7 +897,7 @@ nicvf_dev_tx_queue_release(void *sq)
static void
nicvf_set_tx_function(struct rte_eth_dev *dev)
{
- struct nicvf_txq *txq;
+ struct nicvf_txq *txq = NULL;
size_t i;
bool multiseg = false;
@@ -918,6 +918,9 @@ nicvf_set_tx_function(struct rte_eth_dev *dev)
dev->tx_pkt_burst = nicvf_xmit_pkts;
}
+ if (!txq)
+ return;
+
if (txq->pool_free == nicvf_single_pool_free_xmited_buffers)
PMD_DRV_LOG(DEBUG, "Using single-mempool tx free method");
else