net/bonding: fix MAC address when one port resets
authorWei Hu (Xavier) <xavier.huwei@huawei.com>
Fri, 17 Apr 2020 08:19:18 +0000 (16:19 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 17 Jul 2020 16:21:21 +0000 (18:21 +0200)
commit2d944002762e85e351be7cea432919f159d2ecae
treee1107ed732d67a31a8e2ccbae9f4ead9267cb5fd
parentedf6489ea43ec9c27d54dbe9e94adcdc43b70e04
net/bonding: fix MAC address when one port resets

The current bonding PMD driver call mac_address_slaves_update function
to modify the MAC address of all slaves devices. In
mac_address_slaves_update function, the rte_eth_dev_default_mac_addr_set
API function is called to set the MAC address of the slave devices in
turn in the for loop statement.

When one port reset, calling rte_eth_dev_default_mac_addr_set API fails
because the firmware will not respond to the commands from the driver,
and exit the loop, so other slave devices cannot continue to update the
MAC address.

This patch fixes the issue by avoid exiting the loop when calling
rte_eth_dev_default_mac_addr_set fails.

Fixes: 2efb58cbab6e ("bond: new link bonding library")
Cc: stable@dpdk.org
Signed-off-by: Hongbo Zheng <zhenghongbo3@huawei.com>
Signed-off-by: Wei Hu (Xavier) <xavier.huwei@huawei.com>
Signed-off-by: Chunsong Feng <fengchunsong@huawei.com>
Signed-off-by: Xuan Li <lixuan47@hisilicon.com>
drivers/net/bonding/rte_eth_bond_pmd.c