Merge pull request #272 from CGarces/fix_eth_hw_addr_set

eth_hw_addr_set: use memcpy
This commit is contained in:
Carlos Garcés 2022-05-22 13:12:51 +02:00 committed by GitHub
commit 6ba1f32096
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -221,7 +221,7 @@ typedef unsigned long systime;
/* Porting from linux kernel v5.15-rc1 48eab831ae8b9f7002a533fa4235eed63ea1f1a3 */ /* Porting from linux kernel v5.15-rc1 48eab831ae8b9f7002a533fa4235eed63ea1f1a3 */
static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr) static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr)
{ {
ether_addr_copy(dev->dev_addr, addr); memcpy(dev->dev_addr, addr, ETH_ALEN);
} }
#endif #endif