From dbe26517cd774d2b1a11688c914cc5e3e070aaca Mon Sep 17 00:00:00 2001 From: Andrew Rybchenko Date: Thu, 7 Feb 2019 12:17:41 +0000 Subject: [PATCH] net/sfc: remove unnecessary functions to get TxQ index TxQ index is stored in generic datapath queue structure. Signed-off-by: Andrew Rybchenko --- drivers/net/sfc/sfc_ethdev.c | 2 +- drivers/net/sfc/sfc_tx.h | 12 ------------ 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c index f3316e1435..a00ea9ce40 100644 --- a/drivers/net/sfc/sfc_ethdev.c +++ b/drivers/net/sfc/sfc_ethdev.c @@ -491,7 +491,7 @@ sfc_tx_queue_release(void *queue) return; txq = sfc_txq_by_dp_txq(dp_txq); - sw_index = sfc_txq_sw_index(txq); + sw_index = dp_txq->dpq.queue_id; SFC_ASSERT(txq->evq != NULL); sa = txq->evq->sa; diff --git a/drivers/net/sfc/sfc_tx.h b/drivers/net/sfc/sfc_tx.h index e5ea6df75c..2d21e6e831 100644 --- a/drivers/net/sfc/sfc_tx.h +++ b/drivers/net/sfc/sfc_tx.h @@ -57,18 +57,6 @@ struct sfc_txq { efx_txq_t *common; }; -static inline unsigned int -sfc_txq_sw_index_by_hw_index(unsigned int hw_index) -{ - return hw_index; -} - -static inline unsigned int -sfc_txq_sw_index(const struct sfc_txq *txq) -{ - return sfc_txq_sw_index_by_hw_index(txq->hw_index); -} - struct sfc_txq *sfc_txq_by_dp_txq(const struct sfc_dp_txq *dp_txq); /** -- 2.20.1