diff options
author | Jakub Kicinski <kuba@kernel.org> | 2021-10-01 23:32:20 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-10-02 15:18:25 +0200 |
commit | a96d317fb1a30b9f323548eb2ff05d4e4600ead9 (patch) | |
tree | af0fc5c39eef0461e5e15a6cf2f5d9eac93fd101 /drivers/net/ethernet/nxp/lpc_eth.c | |
parent | net: use eth_hw_addr_set() (diff) | |
download | linux-a96d317fb1a30b9f323548eb2ff05d4e4600ead9.tar.xz linux-a96d317fb1a30b9f323548eb2ff05d4e4600ead9.zip |
ethernet: use eth_hw_addr_set()
Convert all Ethernet drivers from memcpy(... ETH_ADDR)
to eth_hw_addr_set():
@@
expression dev, np;
@@
- memcpy(dev->dev_addr, np, ETH_ALEN)
+ eth_hw_addr_set(dev, np)
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/nxp/lpc_eth.c')
-rw-r--r-- | drivers/net/ethernet/nxp/lpc_eth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/nxp/lpc_eth.c b/drivers/net/ethernet/nxp/lpc_eth.c index d29fe562b3de..11ce9fe435ba 100644 --- a/drivers/net/ethernet/nxp/lpc_eth.c +++ b/drivers/net/ethernet/nxp/lpc_eth.c @@ -1093,7 +1093,7 @@ static int lpc_set_mac_address(struct net_device *ndev, void *p) if (!is_valid_ether_addr(addr->sa_data)) return -EADDRNOTAVAIL; - memcpy(ndev->dev_addr, addr->sa_data, ETH_ALEN); + eth_hw_addr_set(ndev, addr->sa_data); spin_lock_irqsave(&pldat->lock, flags); |