DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [RFC] net/null: add empty promiscuous mode functions
@ 2019-10-16 15:46 Ciara Power
  2019-10-16 18:07 ` Ferruh Yigit
  0 siblings, 1 reply; 16+ messages in thread
From: Ciara Power @ 2019-10-16 15:46 UTC (permalink / raw)
  To: mtetsuyah; +Cc: dev, Ciara Power

Adding promiscuous functions prevents sample applications failing when run
on this virtual PMD. The sample applications call promiscuous functions,
and fail if this function call returns an error, which occurs when the
virtual PMD does not support the promiscuous function being called. 

This change will be implemented for all virtual PMDs that currently do not
have existing promiscuous functions. Multicast functions will also be
added for virtual PMDs to prevent sample application breakages here also.

Signed-off-by: Ciara Power <ciara.power@intel.com>
---
 drivers/net/null/rte_eth_null.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/net/null/rte_eth_null.c b/drivers/net/null/rte_eth_null.c
index e2ff41a22..b8472a0cf 100644
--- a/drivers/net/null/rte_eth_null.c
+++ b/drivers/net/null/rte_eth_null.c
@@ -441,11 +441,25 @@ eth_mac_address_set(__rte_unused struct rte_eth_dev *dev,
 	return 0;
 }
 
+static int
+eth_dev_promiscuous_enable(__rte_unused struct rte_eth_dev *dev)
+{
+	return 0;
+}
+
+static int
+eth_dev_promiscuous_disable(__rte_unused struct rte_eth_dev *dev)
+{
+	return 0;
+}
+
 static const struct eth_dev_ops ops = {
 	.dev_start = eth_dev_start,
 	.dev_stop = eth_dev_stop,
 	.dev_configure = eth_dev_configure,
 	.dev_infos_get = eth_dev_info,
+	.promiscuous_enable = eth_dev_promiscuous_enable,
+	.promiscuous_disable = eth_dev_promiscuous_disable,
 	.rx_queue_setup = eth_rx_queue_setup,
 	.tx_queue_setup = eth_tx_queue_setup,
 	.rx_queue_release = eth_queue_release,
-- 
2.17.1


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

end of thread, other threads:[~2019-10-18 13:38 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-16 15:46 [dpdk-dev] [RFC] net/null: add empty promiscuous mode functions Ciara Power
2019-10-16 18:07 ` Ferruh Yigit
2019-10-17 10:37   ` Andrew Rybchenko
2019-10-17 10:47     ` Ferruh Yigit
2019-10-17 10:51       ` Andrew Rybchenko
2019-10-17 11:05         ` Ferruh Yigit
2019-10-17 13:43           ` Bruce Richardson
2019-10-17 15:33             ` Ferruh Yigit
2019-10-18  8:18               ` Ferruh Yigit
2019-10-18  8:30                 ` Andrew Rybchenko
2019-10-18 10:13               ` Bruce Richardson
2019-10-18 11:38                 ` Ferruh Yigit
2019-10-18 11:57                   ` Andrew Rybchenko
2019-10-18 13:02                     ` Ferruh Yigit
2019-10-18 13:12                   ` Bruce Richardson
2019-10-18 13:38                     ` Ferruh Yigit

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).