]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
arcnet: com20020-pci: add missing pdev setup in netdev structure
authorMichael Grzeschik <m.grzeschik@pengutronix.de>
Wed, 28 Jun 2017 16:28:37 +0000 (18:28 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 29 Jun 2017 19:18:37 +0000 (15:18 -0400)
We add the pdev data to the pci devices netdev structure. This way
the interface get consistent device names in the userspace (udev).

Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/arcnet/com20020-pci.c

index fec2df2c869fe7863bd43a3df1d33380b5980e22..47f80b83dcf42a47666f05a688a680b7690251cf 100644 (file)
@@ -167,6 +167,7 @@ static int com20020pci_probe(struct pci_dev *pdev,
                arcnet_outb(0x00, ioaddr, COM20020_REG_W_COMMAND);
                arcnet_inb(ioaddr, COM20020_REG_R_DIAGSTAT);
 
+               SET_NETDEV_DEV(dev, &pdev->dev);
                dev->base_addr = ioaddr;
                dev->dev_addr[0] = node;
                dev->irq = pdev->irq;