Add the dev_addr_mod() function. Signed-off-by: Hauke Mehrtens <hauke@xxxxxxxxxx> --- backport/backport-include/linux/netdevice.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h index 530cbb07..1ec5b1d2 100644 --- a/backport/backport-include/linux/netdevice.h +++ b/backport/backport-include/linux/netdevice.h @@ -240,4 +240,14 @@ static inline void backport_netif_napi_add_tx(struct net_device *dev, #define netif_napi_add_tx LINUX_BACKPORT(netif_napi_add_tx) #endif /* < 6.1 */ +#if LINUX_VERSION_IS_LESS(5,15,0) +#define dev_addr_mod LINUX_BACKPORT(dev_addr_mod) +static inline void +dev_addr_mod(struct net_device *dev, unsigned int offset, + const void *addr, size_t len) +{ + memcpy(&dev->dev_addr[offset], addr, len); +} +#endif /* < 5.15 */ + #endif /* __BACKPORT_NETDEVICE_H */ -- 2.45.2