aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/8139too.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/8139too.c')
-rw-r--r--drivers/net/8139too.c27
1 files changed, 16 insertions, 11 deletions
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c
index 37456ada44cf..f8866552386a 100644
--- a/drivers/net/8139too.c
+++ b/drivers/net/8139too.c
@@ -916,6 +916,19 @@ err_out:
916 return rc; 916 return rc;
917} 917}
918 918
919static const struct net_device_ops rtl8139_netdev_ops = {
920 .ndo_open = rtl8139_open,
921 .ndo_stop = rtl8139_close,
922 .ndo_get_stats = rtl8139_get_stats,
923 .ndo_validate_addr = eth_validate_addr,
924 .ndo_set_multicast_list = rtl8139_set_rx_mode,
925 .ndo_do_ioctl = netdev_ioctl,
926 .ndo_tx_timeout = rtl8139_tx_timeout,
927#ifdef CONFIG_NET_POLL_CONTROLLER
928 .ndo_poll_controller = rtl8139_poll_controller,
929#endif
930
931};
919 932
920static int __devinit rtl8139_init_one (struct pci_dev *pdev, 933static int __devinit rtl8139_init_one (struct pci_dev *pdev,
921 const struct pci_device_id *ent) 934 const struct pci_device_id *ent)
@@ -976,19 +989,11 @@ static int __devinit rtl8139_init_one (struct pci_dev *pdev,
976 memcpy(dev->perm_addr, dev->dev_addr, dev->addr_len); 989 memcpy(dev->perm_addr, dev->dev_addr, dev->addr_len);
977 990
978 /* The Rtl8139-specific entries in the device structure. */ 991 /* The Rtl8139-specific entries in the device structure. */
979 dev->open = rtl8139_open; 992 dev->netdev_ops = &rtl8139_netdev_ops;
980 dev->hard_start_xmit = rtl8139_start_xmit;
981 netif_napi_add(dev, &tp->napi, rtl8139_poll, 64);
982 dev->stop = rtl8139_close;
983 dev->get_stats = rtl8139_get_stats;
984 dev->set_multicast_list = rtl8139_set_rx_mode;
985 dev->do_ioctl = netdev_ioctl;
986 dev->ethtool_ops = &rtl8139_ethtool_ops; 993 dev->ethtool_ops = &rtl8139_ethtool_ops;
987 dev->tx_timeout = rtl8139_tx_timeout;
988 dev->watchdog_timeo = TX_TIMEOUT; 994 dev->watchdog_timeo = TX_TIMEOUT;
989#ifdef CONFIG_NET_POLL_CONTROLLER 995 dev->hard_start_xmit = rtl8139_start_xmit;
990 dev->poll_controller = rtl8139_poll_controller; 996 netif_napi_add(dev, &tp->napi, rtl8139_poll, 64);
991#endif
992 997
993 /* note: the hardware is not capable of sg/csum/highdma, however 998 /* note: the hardware is not capable of sg/csum/highdma, however
994 * through the use of skb_copy_and_csum_dev we enable these 999 * through the use of skb_copy_and_csum_dev we enable these