OSDN Git Service

net: hns3: add protect when handling mac addr list
authorJian Shen <shenjian15@huawei.com>
Thu, 4 Apr 2019 08:17:55 +0000 (16:17 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 4 Apr 2019 17:20:39 +0000 (10:20 -0700)
commit389775a6605e040dddea21a778a88eaaa57c068d
tree4495649397543853b998e724b0c21a880ce1413d
parentffd0a922cdea3f37438aeb76a154da1775e82626
net: hns3: add protect when handling mac addr list

It used netdev->uc and netdev->mc list in function
hns3_recover_hw_addr() and hns3_remove_hw_addr().
We should add protect for them.

Fixes: f05e21097121 ("net: hns3: Clear mac vlan table entries when unload driver or function reset")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c