diff options
Diffstat (limited to 'drivers/net/via-rhine.c')
-rw-r--r-- | drivers/net/via-rhine.c | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/drivers/net/via-rhine.c b/drivers/net/via-rhine.c index 9a650d0a6795..93b74b7b7077 100644 --- a/drivers/net/via-rhine.c +++ b/drivers/net/via-rhine.c | |||
@@ -614,6 +614,20 @@ static void __devinit rhine_hw_init(struct net_device *dev, long pioaddr) | |||
614 | rhine_reload_eeprom(pioaddr, dev); | 614 | rhine_reload_eeprom(pioaddr, dev); |
615 | } | 615 | } |
616 | 616 | ||
617 | static const struct net_device_ops rhine_netdev_ops = { | ||
618 | .ndo_open = rhine_open, | ||
619 | .ndo_stop = rhine_close, | ||
620 | .ndo_start_xmit = rhine_start_tx, | ||
621 | .ndo_get_stats = rhine_get_stats, | ||
622 | .ndo_set_multicast_list = rhine_set_rx_mode, | ||
623 | .ndo_validate_addr = eth_validate_addr, | ||
624 | .ndo_do_ioctl = netdev_ioctl, | ||
625 | .ndo_tx_timeout = rhine_tx_timeout, | ||
626 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
627 | .ndo_poll_controller = rhine_poll, | ||
628 | #endif | ||
629 | }; | ||
630 | |||
617 | static int __devinit rhine_init_one(struct pci_dev *pdev, | 631 | static int __devinit rhine_init_one(struct pci_dev *pdev, |
618 | const struct pci_device_id *ent) | 632 | const struct pci_device_id *ent) |
619 | { | 633 | { |
@@ -764,18 +778,10 @@ static int __devinit rhine_init_one(struct pci_dev *pdev, | |||
764 | rp->mii_if.reg_num_mask = 0x1f; | 778 | rp->mii_if.reg_num_mask = 0x1f; |
765 | 779 | ||
766 | /* The chip-specific entries in the device structure. */ | 780 | /* The chip-specific entries in the device structure. */ |
767 | dev->open = rhine_open; | 781 | dev->netdev_ops = &rhine_netdev_ops; |
768 | dev->hard_start_xmit = rhine_start_tx; | 782 | dev->ethtool_ops = &netdev_ethtool_ops, |
769 | dev->stop = rhine_close; | ||
770 | dev->get_stats = rhine_get_stats; | ||
771 | dev->set_multicast_list = rhine_set_rx_mode; | ||
772 | dev->do_ioctl = netdev_ioctl; | ||
773 | dev->ethtool_ops = &netdev_ethtool_ops; | ||
774 | dev->tx_timeout = rhine_tx_timeout; | ||
775 | dev->watchdog_timeo = TX_TIMEOUT; | 783 | dev->watchdog_timeo = TX_TIMEOUT; |
776 | #ifdef CONFIG_NET_POLL_CONTROLLER | 784 | |
777 | dev->poll_controller = rhine_poll; | ||
778 | #endif | ||
779 | netif_napi_add(dev, &rp->napi, rhine_napipoll, 64); | 785 | netif_napi_add(dev, &rp->napi, rhine_napipoll, 64); |
780 | 786 | ||
781 | if (rp->quirks & rqRhineI) | 787 | if (rp->quirks & rqRhineI) |