Skip to content

Commit

Permalink
net: um: use eth_hw_addr_set()
Browse files Browse the repository at this point in the history
Commit 406f42f ("net-next: When a bond have a massive amount
of VLANs...") introduced a rbtree for faster Ethernet address look
up. To maintain netdev->dev_addr in this tree we need to make all
the writes to it go through appropriate helpers.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Acked-by: Anton Ivanov <anton.ivanov@cambridgegreys.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jakub Kicinski authored and David S. Miller committed Oct 29, 2021
1 parent 40d5cb4 commit ac61734
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/um/drivers/net_kern.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ static const struct ethtool_ops uml_net_ethtool_ops = {

void uml_net_setup_etheraddr(struct net_device *dev, char *str)
{
unsigned char *addr = dev->dev_addr;
u8 addr[ETH_ALEN];
char *end;
int i;

Expand Down Expand Up @@ -316,6 +316,7 @@ void uml_net_setup_etheraddr(struct net_device *dev, char *str)
addr[0] | 0x02, addr[1], addr[2], addr[3], addr[4],
addr[5]);
}
eth_hw_addr_set(dev, addr);
return;

random:
Expand Down

0 comments on commit ac61734

Please sign in to comment.