net: hns3: Only update mac configuation when necessary
authorYunsheng Lin <linyunsheng@huawei.com>
Mon, 3 Sep 2018 10:21:53 +0000 (11:21 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 4 Sep 2018 05:04:45 +0000 (22:04 -0700)
commit2d03eacc0b7e7aeedce6032f79872f3fd3d1a94f
tree64d407022951307ff6a848f5c70cb66910d6daf5
parentdaaa8521760ee4d4e65f309c4c37b3a1e58c9d4e
net: hns3: Only update mac configuation when necessary

Currently only fiber port checks if it is necessay to set the
mac through firmware when link is changed, this patch unify the
checking to allow the copper port do the checking too.

Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c