diff mbox series

[3/8] net/iavf: re-program promiscuous mode on VF interface

Message ID 20200927072626.28374-4-robinx.zhang@intel.com (mailing list archive)
State Accepted, archived
Delegated to: Qi Zhang
Headers show
Series feature porting from i40evf to iavf | expand

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Robin Zhang Sept. 27, 2020, 7:26 a.m. UTC
During a kernel PF reset, this event is propagated to the VF.
The DPDK VF PMD will execute the reset task before the PF is done
with his. This results in the admin queue message not being responded
to leaving the port in "promiscuous" mode.

This patch makes sure the promiscuous mode is configured independently
of the current admin state.

Signed-off-by: Robin Zhang <robinx.zhang@intel.com>
---
 drivers/net/iavf/iavf_ethdev.c | 12 ------------
 1 file changed, 12 deletions(-)
diff mbox series

Patch

diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
index d21e35c17..57640c52a 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
@@ -678,9 +678,6 @@  iavf_dev_promiscuous_enable(struct rte_eth_dev *dev)
 	struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);
 	int ret;
 
-	if (vf->promisc_unicast_enabled)
-		return 0;
-
 	ret = iavf_config_promisc(adapter, true, vf->promisc_multicast_enabled);
 	if (!ret)
 		vf->promisc_unicast_enabled = true;
@@ -700,9 +697,6 @@  iavf_dev_promiscuous_disable(struct rte_eth_dev *dev)
 	struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);
 	int ret;
 
-	if (!vf->promisc_unicast_enabled)
-		return 0;
-
 	ret = iavf_config_promisc(adapter, false,
 				  vf->promisc_multicast_enabled);
 	if (!ret)
@@ -723,9 +717,6 @@  iavf_dev_allmulticast_enable(struct rte_eth_dev *dev)
 	struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);
 	int ret;
 
-	if (vf->promisc_multicast_enabled)
-		return 0;
-
 	ret = iavf_config_promisc(adapter, vf->promisc_unicast_enabled, true);
 	if (!ret)
 		vf->promisc_multicast_enabled = true;
@@ -745,9 +736,6 @@  iavf_dev_allmulticast_disable(struct rte_eth_dev *dev)
 	struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);
 	int ret;
 
-	if (!vf->promisc_multicast_enabled)
-		return 0;
-
 	ret = iavf_config_promisc(adapter, vf->promisc_unicast_enabled, false);
 	if (!ret)
 		vf->promisc_multicast_enabled = false;