Commit 09ec0d05 authored by Luka Perkov's avatar Luka Perkov Committed by David S. Miller

octeon_mgmt: drop redundant mac address check

Checking if MAC address is valid using is_valid_ether_addr() is already done in
of_get_mac_address().
Signed-off-by: default avatarLuka Perkov <luka@openwrt.org>
Acked-by: default avatarDavid Daney <david.daney@cavium.com>
CC: David Miller <davem@davemloft.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c968601d
...@@ -1545,7 +1545,7 @@ static int octeon_mgmt_probe(struct platform_device *pdev) ...@@ -1545,7 +1545,7 @@ static int octeon_mgmt_probe(struct platform_device *pdev)
mac = of_get_mac_address(pdev->dev.of_node); mac = of_get_mac_address(pdev->dev.of_node);
if (mac && is_valid_ether_addr(mac)) if (mac)
memcpy(netdev->dev_addr, mac, ETH_ALEN); memcpy(netdev->dev_addr, mac, ETH_ALEN);
else else
eth_hw_addr_random(netdev); eth_hw_addr_random(netdev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment