diff options
author | Jakub Kicinski <kuba@kernel.org> | 2021-10-21 16:12:14 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-10-22 20:16:18 +0300 |
commit | 65a4fbbf22636af5dd110fc272fac6b0d84e42fc (patch) | |
tree | 6fee94dcb692caf04b04f6cf8d5bf9b0757c1c93 | |
parent | 5f07da89bcd0759ac8391b917245a07fbdcf9234 (diff) | |
download | linux-65a4fbbf22636af5dd110fc272fac6b0d84e42fc.tar.xz |
net: hldc_fr: use dev_addr_set()
Commit 406f42fa0d3c ("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 got through appropriate helpers.
Acked-by: Krzysztof HaĆasa <khalasa@piap.pl>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r-- | drivers/net/wan/hdlc_fr.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/wan/hdlc_fr.c b/drivers/net/wan/hdlc_fr.c index 7637edce443e..81e72bc1891f 100644 --- a/drivers/net/wan/hdlc_fr.c +++ b/drivers/net/wan/hdlc_fr.c @@ -1093,7 +1093,9 @@ static int fr_add_pvc(struct net_device *frad, unsigned int dlci, int type) dev->priv_flags &= ~IFF_TX_SKB_SHARING; eth_hw_addr_random(dev); } else { - *(__be16 *)dev->dev_addr = htons(dlci); + __be16 addr = htons(dlci); + + dev_addr_set(dev, (u8 *)&addr); dlci_to_q922(dev->broadcast, dlci); } dev->netdev_ops = &pvc_ops; |