Skip to content

Commit

Permalink
net/hsr: use eth_hw_addr_random()
Browse files Browse the repository at this point in the history
Use eth_hw_addr_random() to set a random MAC address in order to make sure
dev->addr_assign_type will be properly set to NET_ADDR_RANDOM.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Tobias Klauser authored and David S. Miller committed Feb 21, 2017
1 parent 32cc1bb commit d4af4c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/hsr/hsr_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ static struct device_type hsr_type = {

void hsr_dev_setup(struct net_device *dev)
{
random_ether_addr(dev->dev_addr);
eth_hw_addr_random(dev);

ether_setup(dev);
dev->min_mtu = 0;
Expand Down

0 comments on commit d4af4c0

Please sign in to comment.