Commit d08f161a authored by Joe Perches's avatar Joe Perches Committed by David S. Miller

dsa: Use ether_addr_copy

Use ether_addr_copy instead of memcpy(a, b, ETH_ALEN) to
save some cycles on arm and powerpc.
Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9ea08b12
...@@ -156,7 +156,7 @@ static int dsa_slave_set_mac_address(struct net_device *dev, void *a) ...@@ -156,7 +156,7 @@ static int dsa_slave_set_mac_address(struct net_device *dev, void *a)
dev_uc_del(master, dev->dev_addr); dev_uc_del(master, dev->dev_addr);
out: out:
memcpy(dev->dev_addr, addr->sa_data, ETH_ALEN); ether_addr_copy(dev->dev_addr, addr->sa_data);
return 0; return 0;
} }
......
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