diff options
author | Jakub Kicinski <kuba@kernel.org> | 2021-10-13 23:44:32 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-10-14 19:22:19 +0300 |
commit | c51e5062c18067ccdc85798c2051edfc37e2475d (patch) | |
tree | b1db6aa8ffd5025c60317701cb29b5676156726c /drivers/net/usb/pegasus.c | |
parent | db0dcc6a8a7c9051f9228c0f745f1e1d029ae4fa (diff) | |
download | linux-c51e5062c18067ccdc85798c2051edfc37e2475d.tar.xz |
ethernet: manually convert memcpy(dev_addr,..., sizeof(addr))
A handful of drivers use sizeof(addr) for the size of
the address, after manually confirming the size is
indeed 6 convert them to eth_hw_addr_set().
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Petko Manolov <petkan@nucleusys.com>
Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/usb/pegasus.c')
-rw-r--r-- | drivers/net/usb/pegasus.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c index 6a92a3fef75e..c4cd40b090fd 100644 --- a/drivers/net/usb/pegasus.c +++ b/drivers/net/usb/pegasus.c @@ -357,7 +357,7 @@ static void set_ethernet_addr(pegasus_t *pegasus) goto err; } - memcpy(pegasus->net->dev_addr, node_id, sizeof(node_id)); + eth_hw_addr_set(pegasus->net, node_id); return; err: |