summaryrefslogtreecommitdiff
path: root/drivers/net/ixgbe
diff options
context:
space:
mode:
authorWei Zhao <wei.zhao1@intel.com>2019-03-08 10:46:16 +0800
committerFerruh Yigit <ferruh.yigit@intel.com>2019-03-08 17:52:22 +0100
commit1f4564ed7696d55451563774b11d9b1aa92523dc (patch)
treee39743fb171cb682964f3afaee2edaad4e327363 /drivers/net/ixgbe
parentfd350d3c9a13b5ebcb41741870c3f09b6920033f (diff)
downloaddpdk-next-eventdev-1f4564ed7696d55451563774b11d9b1aa92523dc.zip
dpdk-next-eventdev-1f4564ed7696d55451563774b11d9b1aa92523dc.tar.gz
dpdk-next-eventdev-1f4564ed7696d55451563774b11d9b1aa92523dc.tar.xz
net/ixgbevf: enable promiscuous mode
Add promiscuous mode support on VF Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Diffstat (limited to 'drivers/net/ixgbe')
-rw-r--r--drivers/net/ixgbe/ixgbe_ethdev.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index c336937..3bf51ee 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -260,6 +260,8 @@ static int ixgbevf_dev_rx_queue_intr_disable(struct rte_eth_dev *dev,
static void ixgbevf_set_ivar_map(struct ixgbe_hw *hw, int8_t direction,
uint8_t queue, uint8_t msix_vector);
static void ixgbevf_configure_msix(struct rte_eth_dev *dev);
+static void ixgbevf_dev_promiscuous_enable(struct rte_eth_dev *dev);
+static void ixgbevf_dev_promiscuous_disable(struct rte_eth_dev *dev);
static void ixgbevf_dev_allmulticast_enable(struct rte_eth_dev *dev);
static void ixgbevf_dev_allmulticast_disable(struct rte_eth_dev *dev);
@@ -596,6 +598,8 @@ static const struct eth_dev_ops ixgbevf_eth_dev_ops = {
.xstats_get_names = ixgbevf_dev_xstats_get_names,
.dev_close = ixgbevf_dev_close,
.dev_reset = ixgbevf_dev_reset,
+ .promiscuous_enable = ixgbevf_dev_promiscuous_enable,
+ .promiscuous_disable = ixgbevf_dev_promiscuous_disable,
.allmulticast_enable = ixgbevf_dev_allmulticast_enable,
.allmulticast_disable = ixgbevf_dev_allmulticast_disable,
.dev_infos_get = ixgbevf_dev_info_get,
@@ -8310,6 +8314,22 @@ ixgbe_dev_udp_tunnel_port_del(struct rte_eth_dev *dev,
}
static void
+ixgbevf_dev_promiscuous_enable(struct rte_eth_dev *dev)
+{
+ struct ixgbe_hw *hw = IXGBE_DEV_PRIVATE_TO_HW(dev->data->dev_private);
+
+ hw->mac.ops.update_xcast_mode(hw, IXGBEVF_XCAST_MODE_PROMISC);
+}
+
+static void
+ixgbevf_dev_promiscuous_disable(struct rte_eth_dev *dev)
+{
+ struct ixgbe_hw *hw = IXGBE_DEV_PRIVATE_TO_HW(dev->data->dev_private);
+
+ hw->mac.ops.update_xcast_mode(hw, IXGBEVF_XCAST_MODE_NONE);
+}
+
+static void
ixgbevf_dev_allmulticast_enable(struct rte_eth_dev *dev)
{
struct ixgbe_hw *hw = IXGBE_DEV_PRIVATE_TO_HW(dev->data->dev_private);