DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev]  [PATCH] ethdev: add lock-less txq capability flag
@ 2017-04-21 12:22 Jerin Jacob
  2017-04-24 12:34 ` Thomas Monjalon
  2017-07-06  6:21 ` [dpdk-dev] [PATCH v2] ethdev: introduce lock-free " Jerin Jacob
  0 siblings, 2 replies; 12+ messages in thread
From: Jerin Jacob @ 2017-04-21 12:22 UTC (permalink / raw)
  To: dev
  Cc: thomas, bruce.richardson, harry.van.haaren, hemant.agrawal,
	gage.eads, nipun.gupta, santosh.shukla, Jerin Jacob

if this flag is advertised by a PMD, Multiple threads can
invoke rte_eth_tx_burst() concurrently on the same tx queue
without SW lock. This is an HW feature found in some NICs
and useful in the following use cases if HW supports it.

1) Remove explicit spinlock in some application where cores
to tx queues are not mapped 1:1.
example: OVS has such instance
https://github.com/openvswitch/ovs/blob/master/lib/netdev-dpdk.c#L292
https://github.com/openvswitch/ovs/blob/master/lib/netdev-dpdk.c#L1821

2) In eventdev use case, Avoid dedicating a separate tx core
for transmit and thus enables more scaling as all workers
can transmit the packets.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
---
 lib/librte_ether/rte_ethdev.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index f9de9a2b6..696bc9d44 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -899,6 +899,10 @@ struct rte_eth_conf {
 #define DEV_TX_OFFLOAD_IPIP_TNL_TSO     0x00000800    /**< Used for tunneling packet. */
 #define DEV_TX_OFFLOAD_GENEVE_TNL_TSO   0x00001000    /**< Used for tunneling packet. */
 #define DEV_TX_OFFLOAD_MACSEC_INSERT    0x00002000
+#define DEV_TX_OFFLOAD_TXQ_MT_LOCKFREE	0x00004000
+/**< Multiple threads can invoke rte_eth_tx_burst() concurrently on the same
+ * tx queue without SW lock.
+ */
 
 struct rte_pci_device;
 
-- 
2.12.2

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2017-07-18 13:43 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-21 12:22 [dpdk-dev] [PATCH] ethdev: add lock-less txq capability flag Jerin Jacob
2017-04-24 12:34 ` Thomas Monjalon
2017-04-27 11:00   ` Jerin Jacob
2017-07-05 17:46     ` Thomas Monjalon
2017-07-06  6:00       ` Jerin Jacob
2017-07-06  6:21 ` [dpdk-dev] [PATCH v2] ethdev: introduce lock-free " Jerin Jacob
2017-07-08 16:08   ` Thomas Monjalon
2017-07-10 16:56     ` Jerin Jacob
2017-07-10 16:59   ` [dpdk-dev] [PATCH v3 ] " Jerin Jacob
2017-07-13 12:02     ` Hemant Agrawal
2017-07-18 13:43       ` Thomas Monjalon
2017-07-13 18:42     ` santosh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).