Patchwork [dpdk-dev,17/30] net/sfc: remove unnecessary functions to get RxQ index

login
register
mail settings
Submitter Andrew Rybchenko
Date Feb. 7, 2019, 12:17 p.m.
Message ID <1549541873-17403-18-git-send-email-arybchenko@solarflare.com>
Download mbox | patch
Permalink /patch/720429/
State New
Headers show

Comments

Andrew Rybchenko - Feb. 7, 2019, 12:17 p.m.
RxQ index is stored in generic datapath queue structure.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/net/sfc/sfc_ethdev.c |  2 +-
 drivers/net/sfc/sfc_rx.h     | 12 ------------
 2 files changed, 1 insertion(+), 13 deletions(-)

Patch

diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c
index 47450f6b2..f3316e143 100644
--- a/drivers/net/sfc/sfc_ethdev.c
+++ b/drivers/net/sfc/sfc_ethdev.c
@@ -442,7 +442,7 @@  sfc_rx_queue_release(void *queue)
 	sa = rxq->evq->sa;
 	sfc_adapter_lock(sa);
 
-	sw_index = sfc_rxq_sw_index(rxq);
+	sw_index = dp_rxq->dpq.queue_id;
 
 	sfc_log_init(sa, "RxQ=%u", sw_index);
 
diff --git a/drivers/net/sfc/sfc_rx.h b/drivers/net/sfc/sfc_rx.h
index 9c946d7cb..963d487c0 100644
--- a/drivers/net/sfc/sfc_rx.h
+++ b/drivers/net/sfc/sfc_rx.h
@@ -61,18 +61,6 @@  struct sfc_rxq {
 	uint16_t		buf_size;
 };
 
-static inline unsigned int
-sfc_rxq_sw_index_by_hw_index(unsigned int hw_index)
-{
-	return hw_index;
-}
-
-static inline unsigned int
-sfc_rxq_sw_index(const struct sfc_rxq *rxq)
-{
-	return sfc_rxq_sw_index_by_hw_index(rxq->hw_index);
-}
-
 struct sfc_rxq *sfc_rxq_by_dp_rxq(const struct sfc_dp_rxq *dp_rxq);
 
 /**