From: John W. Linville Date: Mon, 12 Sep 2005 14:48:54 +0000 (-0400) Subject: [PATCH] 8139cp: support ETHTOOL_GPERMADDR X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=bb0ce608a3386268bd76ee6642a4cc8e6818a29b;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [PATCH] 8139cp: support ETHTOOL_GPERMADDR Add support for ETHTOOL_GPERMADDR to 8139cp. Signed-off-by: John W. Linville Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c index 34b80de34fae..ebc20d9e7d7b 100644 --- a/drivers/net/8139cp.c +++ b/drivers/net/8139cp.c @@ -1575,6 +1575,7 @@ static struct ethtool_ops cp_ethtool_ops = { .set_wol = cp_set_wol, .get_strings = cp_get_strings, .get_ethtool_stats = cp_get_ethtool_stats, + .get_perm_addr = ethtool_op_get_perm_addr, }; static int cp_ioctl (struct net_device *dev, struct ifreq *rq, int cmd) @@ -1773,6 +1774,7 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) for (i = 0; i < 3; i++) ((u16 *) (dev->dev_addr))[i] = le16_to_cpu (read_eeprom (regs, i + 7, addr_len)); + memcpy(dev->perm_addr, dev->dev_addr, dev->addr_len); dev->open = cp_open; dev->stop = cp_close;