Skip to contentSkip to conversation

eal: remove unnecessary #ifdef CONFIG_BQL

PATCH In review Alex Gartrell 3 participants 3 messages Mar 13, 2015 – Mar 24, 2015 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 eal: remove unnecessary #ifdef CONFIG_BQL

I couldn't figure out why this #ifdef existed so I looked around upstream and it's not there. It seems to build just fine without it.

---
 lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h | 2 --
 1 file changed, 2 deletions(-)
lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h +0 -2
index a582f52..d58e1f3 100644
@@ -472,12 +472,10 @@ static inline u16 igb_desc_unused(const struct igb_ring *ring)
 	return ((ntc > ntu) ? 0 : ring->count) + ntc - ntu - 1;
 }
 
-#ifdef CONFIG_BQL
 static inline struct netdev_queue *txring_txq(const struct igb_ring *tx_ring)
 {
 	return netdev_get_tx_queue(tx_ring->netdev, tx_ring->queue_index);
 }
-#endif /* CONFIG_BQL */
 
 // #ifdef EXT_THERMAL_SENSOR_SUPPORT
 // #ifdef IGB_PROCFS
Signature · 1 line
Alex Gartrell <[email protected]>

A message that is not in the archive (sent off-list or not yet received): 1426274503-372191-1-git-send-email-agartrell-b10kYP2dOMg@public.gmane.org

#2 lore raw

Helin, any comment about this trivial patch?

2015-03-13 12:21, Alex Gartrell:

Quoted 26 lines

I couldn't figure out why this #ifdef existed so I looked around upstream and it's not there. It seems to build just fine without it.

---
 lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h | 2 --
 1 file changed, 2 deletions(-)
lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h +0 -2
index a582f52..d58e1f3 100644
@@ -472,12 +472,10 @@ static inline u16 igb_desc_unused(const struct igb_ring *ring)
 	return ((ntc > ntu) ? 0 : ring->count) + ntc - ntu - 1;
 }
 
-#ifdef CONFIG_BQL
 static inline struct netdev_queue *txring_txq(const struct igb_ring *tx_ring)
 {
 	return netdev_get_tx_queue(tx_ring->netdev, tx_ring->queue_index);
 }
-#endif /* CONFIG_BQL */
 
 // #ifdef EXT_THERMAL_SENSOR_SUPPORT
 // #ifdef IGB_PROCFS
#3 lore raw
In reply to a message not in the archive

Hi Alex

Quoted 9 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Alex Gartrell
Sent: Saturday, March 14, 2015 3:22 AM
To: [email protected]
Cc: [email protected]
Subject: [dpdk-dev] [PATCH] eal: remove unnecessary #ifdef CONFIG_BQL

I couldn't figure out why this #ifdef existed so I looked around upstream and it's not there. It seems to build just fine without it.

You can see in igb/kcomat.h of below code section.

#ifndef CONFIG_BQL
#define netdev_tx_completed_queue(_q, _p, _b) do {} while (0) #define netdev_completed_queue(_n, _p, _b) do {} while (0) #define netdev_tx_sent_queue(_q, _b) do {} while (0) #define netdev_sent_queue(_n, _b) do {} while (0) #define netdev_tx_reset_queue(_q) do {} while (0) #define netdev_reset_queue(_n) do {} while (0) #endif

That means all callers of txring_txq() are conditional compiled. I don't think your modifications are needed.

Regards,
Helin

Quoted 25 lines
---
 lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h | 2 --
 1 file changed, 2 deletions(-)
lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h +0 -3
index a582f52..d58e1f3 100644
@@ -472,12 +472,10 @@ static inline u16 igb_desc_unused(const struct
 igb_ring *ring)
 	return ((ntc > ntu) ? 0 : ring->count) + ntc - ntu - 1;  }
 
-#ifdef CONFIG_BQL
 static inline struct netdev_queue *txring_txq(const struct igb_ring *tx_ring)
 {
 	return netdev_get_tx_queue(tx_ring->netdev, tx_ring->queue_index);  }
-#endif /* CONFIG_BQL */
 
 // #ifdef EXT_THERMAL_SENSOR_SUPPORT
 // #ifdef IGB_PROCFS
--

Alex Gartrell <[email protected]>