]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
hinic: fix a bug in set rx mode
authorXue Chaojing <xuechaojing@huawei.com>
Tue, 18 Jun 2019 00:26:07 +0000 (18:26 -0600)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Tue, 2 Jul 2019 12:18:49 +0000 (14:18 +0200)
BugLink: https://bugs.launchpad.net/bugs/1832048
in set_rx_mode, __dev_mc_sync and netdev_for_each_mc_addr will
repeatedly set the multicast mac address. so we delete this loop.

Signed-off-by: Xue Chaojing <xuechaojing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 66350023d57560b2ead168af098fc507e58d8e6a linux-next)
Signed-off-by: dann frazier <dann.frazier@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/net/ethernet/huawei/hinic/hinic_main.c

index da323b9e1f62fbd4b677deed68320f7879fd58aa..51f0bc8775b04b65361c1f5392beedf306fc29a6 100644 (file)
@@ -723,7 +723,6 @@ static void set_rx_mode(struct work_struct *work)
 {
        struct hinic_rx_mode_work *rx_mode_work = work_to_rx_mode_work(work);
        struct hinic_dev *nic_dev = rx_mode_work_to_nic_dev(rx_mode_work);
-       struct netdev_hw_addr *ha;
 
        netif_info(nic_dev, drv, nic_dev->netdev, "set rx mode work\n");
 
@@ -731,9 +730,6 @@ static void set_rx_mode(struct work_struct *work)
 
        __dev_uc_sync(nic_dev->netdev, add_mac_addr, remove_mac_addr);
        __dev_mc_sync(nic_dev->netdev, add_mac_addr, remove_mac_addr);
-
-       netdev_for_each_mc_addr(ha, nic_dev->netdev)
-               add_mac_addr(nic_dev->netdev, ha->addr);
 }
 
 static void hinic_set_rx_mode(struct net_device *netdev)