diff options
author | Jakub Kicinski <kuba@kernel.org> | 2021-10-02 00:32:28 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-10-02 16:18:26 +0300 |
commit | 16be9a16340b1cec90be018162e434c8bdd1fcd1 (patch) | |
tree | fc737b1464f6d6faaa12c636506bc78b51208d9c /drivers/net/ethernet/cortina | |
parent | 4d3d2c8dba360e5f8a9bf9d4b4f7d829e9812593 (diff) | |
download | linux-16be9a16340b1cec90be018162e434c8bdd1fcd1.tar.xz |
ethernet: use eth_hw_addr_set() - casts
eth_hw_addr_set() takes a u8 pointer, like other
etherdevice helpers. Convert the few drivers which
require casts because they memcpy from "endian marked"
types.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/cortina')
-rw-r--r-- | drivers/net/ethernet/cortina/gemini.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/cortina/gemini.c b/drivers/net/ethernet/cortina/gemini.c index bcbe73374666..82d32caf1374 100644 --- a/drivers/net/ethernet/cortina/gemini.c +++ b/drivers/net/ethernet/cortina/gemini.c @@ -2467,7 +2467,7 @@ static int gemini_ethernet_port_probe(struct platform_device *pdev) DEFAULT_NAPI_WEIGHT); if (is_valid_ether_addr((void *)port->mac_addr)) { - memcpy(netdev->dev_addr, port->mac_addr, ETH_ALEN); + eth_hw_addr_set(netdev, (u8 *)port->mac_addr); } else { dev_dbg(dev, "ethernet address 0x%08x%08x%08x invalid\n", port->mac_addr[0], port->mac_addr[1], |