hc
2024-10-22 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5
kernel/include/linux/etherdevice.h
....@@ -300,6 +300,18 @@
300300 }
301301
302302 /**
303
+ * eth_hw_addr_set - Assign Ethernet address to a net_device
304
+ * @dev: pointer to net_device structure
305
+ * @addr: address to assign
306
+ *
307
+ * Assign given address to the net_device, addr_assign_type is not changed.
308
+ */
309
+static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr)
310
+{
311
+ ether_addr_copy(dev->dev_addr, addr);
312
+}
313
+
314
+/**
303315 * eth_hw_addr_inherit - Copy dev_addr from another net_device
304316 * @dst: pointer to net_device to copy dev_addr to
305317 * @src: pointer to net_device to copy dev_addr from