From: Radu Nicolau Date: Thu, 25 Jan 2018 11:31:44 +0000 (+0000) Subject: net/bonding: add MAC set operation X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=1e4a3cf6fa4c7a53b152c1221891c94c2da6d467;p=dpdk.git net/bonding: add MAC set operation Fixes: aa7791ba8de0 ("net/bonding: fix setting slave MAC addresses") Signed-off-by: Radu Nicolau --- diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c index 158f3aa1d1..a86bcaf603 100644 --- a/drivers/net/bonding/rte_eth_bond_pmd.c +++ b/drivers/net/bonding/rte_eth_bond_pmd.c @@ -2851,6 +2851,13 @@ bond_ethdev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu) return 0; } +static void +bond_ethdev_mac_address_set(struct rte_eth_dev *dev, struct ether_addr *addr) +{ + if (mac_address_set(dev, addr)) + RTE_BOND_LOG(ERR, "Failed to update MAC address"); +} + const struct eth_dev_ops default_dev_ops = { .dev_start = bond_ethdev_start, .dev_stop = bond_ethdev_stop, @@ -2871,7 +2878,8 @@ const struct eth_dev_ops default_dev_ops = { .reta_query = bond_ethdev_rss_reta_query, .rss_hash_update = bond_ethdev_rss_hash_update, .rss_hash_conf_get = bond_ethdev_rss_hash_conf_get, - .mtu_set = bond_ethdev_mtu_set + .mtu_set = bond_ethdev_mtu_set, + .mac_addr_set = bond_ethdev_mac_address_set }; static int