Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dfda3578 authored by Francois Romieu's avatar Francois Romieu
Browse files

via-velocity: stop using net_device.{base_addr, irq}.



Signed-off-by: default avatarFrancois Romieu <romieu@fr.zoreil.com>
Cc: David Lv <DavidLv@viatech.com.cn>
parent 0ca0aa08
Loading
Loading
Loading
Loading
+2 −7
Original line number Original line Diff line number Diff line
@@ -2488,8 +2488,8 @@ static int velocity_close(struct net_device *dev)


	if (vptr->flags & VELOCITY_FLAGS_WOL_ENABLED)
	if (vptr->flags & VELOCITY_FLAGS_WOL_ENABLED)
		velocity_get_ip(vptr);
		velocity_get_ip(vptr);
	if (dev->irq != 0)

		free_irq(dev->irq, dev);
	free_irq(vptr->pdev->irq, dev);


	velocity_free_rings(vptr);
	velocity_free_rings(vptr);


@@ -2755,8 +2755,6 @@ static int __devinit velocity_found1(struct pci_dev *pdev, const struct pci_devi
	if (ret < 0)
	if (ret < 0)
		goto err_free_dev;
		goto err_free_dev;


	dev->irq = pdev->irq;

	ret = velocity_get_pci_info(vptr, pdev);
	ret = velocity_get_pci_info(vptr, pdev);
	if (ret < 0) {
	if (ret < 0) {
		/* error message already printed */
		/* error message already printed */
@@ -2779,8 +2777,6 @@ static int __devinit velocity_found1(struct pci_dev *pdev, const struct pci_devi


	mac_wol_reset(regs);
	mac_wol_reset(regs);


	dev->base_addr = vptr->ioaddr;

	for (i = 0; i < 6; i++)
	for (i = 0; i < 6; i++)
		dev->dev_addr[i] = readb(&regs->PAR[i]);
		dev->dev_addr[i] = readb(&regs->PAR[i]);


@@ -2806,7 +2802,6 @@ static int __devinit velocity_found1(struct pci_dev *pdev, const struct pci_devi


	vptr->phy_id = MII_GET_PHY_ID(vptr->mac_regs);
	vptr->phy_id = MII_GET_PHY_ID(vptr->mac_regs);


	dev->irq = pdev->irq;
	dev->netdev_ops = &velocity_netdev_ops;
	dev->netdev_ops = &velocity_netdev_ops;
	dev->ethtool_ops = &velocity_ethtool_ops;
	dev->ethtool_ops = &velocity_ethtool_ops;
	netif_napi_add(dev, &vptr->napi, velocity_poll, VELOCITY_NAPI_WEIGHT);
	netif_napi_add(dev, &vptr->napi, velocity_poll, VELOCITY_NAPI_WEIGHT);