diff options
-rw-r--r-- | drivers/net/Makefile | 2 | ||||
-rw-r--r-- | drivers/net/arm/Makefile | 2 | ||||
-rw-r--r-- | drivers/net/arm/etherh.c | 19 | ||||
-rw-r--r-- | drivers/net/mac8390.c | 22 |
4 files changed, 34 insertions, 11 deletions
diff --git a/drivers/net/Makefile b/drivers/net/Makefile index 5f3baca3620d..f664e8ddfd40 100644 --- a/drivers/net/Makefile +++ b/drivers/net/Makefile | |||
@@ -97,7 +97,7 @@ obj-$(CONFIG_HAMACHI) += hamachi.o | |||
97 | obj-$(CONFIG_NET) += Space.o loopback.o | 97 | obj-$(CONFIG_NET) += Space.o loopback.o |
98 | obj-$(CONFIG_SEEQ8005) += seeq8005.o | 98 | obj-$(CONFIG_SEEQ8005) += seeq8005.o |
99 | obj-$(CONFIG_NET_SB1000) += sb1000.o | 99 | obj-$(CONFIG_NET_SB1000) += sb1000.o |
100 | obj-$(CONFIG_MAC8390) += mac8390.o | 100 | obj-$(CONFIG_MAC8390) += mac8390.o 8390.o |
101 | obj-$(CONFIG_APNE) += apne.o 8390.o | 101 | obj-$(CONFIG_APNE) += apne.o 8390.o |
102 | obj-$(CONFIG_PCMCIA_PCNET) += 8390.o | 102 | obj-$(CONFIG_PCMCIA_PCNET) += 8390.o |
103 | obj-$(CONFIG_HP100) += hp100.o | 103 | obj-$(CONFIG_HP100) += hp100.o |
diff --git a/drivers/net/arm/Makefile b/drivers/net/arm/Makefile index 7c812ac2b6a5..1a8654019dc8 100644 --- a/drivers/net/arm/Makefile +++ b/drivers/net/arm/Makefile | |||
@@ -4,7 +4,7 @@ | |||
4 | # | 4 | # |
5 | 5 | ||
6 | obj-$(CONFIG_ARM_AM79C961A) += am79c961a.o | 6 | obj-$(CONFIG_ARM_AM79C961A) += am79c961a.o |
7 | obj-$(CONFIG_ARM_ETHERH) += etherh.o | 7 | obj-$(CONFIG_ARM_ETHERH) += etherh.o ../8390.o |
8 | obj-$(CONFIG_ARM_ETHER3) += ether3.o | 8 | obj-$(CONFIG_ARM_ETHER3) += ether3.o |
9 | obj-$(CONFIG_ARM_ETHER1) += ether1.o | 9 | obj-$(CONFIG_ARM_ETHER1) += ether1.o |
10 | obj-$(CONFIG_ARM_AT91_ETHER) += at91_ether.o | 10 | obj-$(CONFIG_ARM_AT91_ETHER) += at91_ether.o |
diff --git a/drivers/net/arm/etherh.c b/drivers/net/arm/etherh.c index 9eb9d1bedc85..6278606d1049 100644 --- a/drivers/net/arm/etherh.c +++ b/drivers/net/arm/etherh.c | |||
@@ -637,6 +637,21 @@ static const struct ethtool_ops etherh_ethtool_ops = { | |||
637 | .get_drvinfo = etherh_get_drvinfo, | 637 | .get_drvinfo = etherh_get_drvinfo, |
638 | }; | 638 | }; |
639 | 639 | ||
640 | static const struct net_device_ops etherh_netdev_ops = { | ||
641 | .ndo_open = etherh_open, | ||
642 | .ndo_stop = etherh_close, | ||
643 | .ndo_set_config = etherh_set_config, | ||
644 | .ndo_start_xmit = ei_start_xmit, | ||
645 | .ndo_tx_timeout = ei_tx_timeout, | ||
646 | .ndo_get_stats = ei_get_stats, | ||
647 | .ndo_set_multicast_list = ei_set_multicast_list, | ||
648 | .ndo_validate_addr = eth_validate_addr, | ||
649 | .ndo_change_mtu = eth_change_mtu, | ||
650 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
651 | .ndo_poll_controller = ei_poll, | ||
652 | #endif | ||
653 | }; | ||
654 | |||
640 | static u32 etherh_regoffsets[16]; | 655 | static u32 etherh_regoffsets[16]; |
641 | static u32 etherm_regoffsets[16]; | 656 | static u32 etherm_regoffsets[16]; |
642 | 657 | ||
@@ -663,9 +678,7 @@ etherh_probe(struct expansion_card *ec, const struct ecard_id *id) | |||
663 | 678 | ||
664 | SET_NETDEV_DEV(dev, &ec->dev); | 679 | SET_NETDEV_DEV(dev, &ec->dev); |
665 | 680 | ||
666 | dev->open = etherh_open; | 681 | dev->netdev_ops = ðerh_netdev_ops; |
667 | dev->stop = etherh_close; | ||
668 | dev->set_config = etherh_set_config; | ||
669 | dev->irq = ec->irq; | 682 | dev->irq = ec->irq; |
670 | dev->ethtool_ops = ðerh_ethtool_ops; | 683 | dev->ethtool_ops = ðerh_ethtool_ops; |
671 | 684 | ||
diff --git a/drivers/net/mac8390.c b/drivers/net/mac8390.c index 98e3eb2697c9..57716e22660c 100644 --- a/drivers/net/mac8390.c +++ b/drivers/net/mac8390.c | |||
@@ -304,7 +304,7 @@ struct net_device * __init mac8390_probe(int unit) | |||
304 | if (!MACH_IS_MAC) | 304 | if (!MACH_IS_MAC) |
305 | return ERR_PTR(-ENODEV); | 305 | return ERR_PTR(-ENODEV); |
306 | 306 | ||
307 | dev = ____alloc_ei_netdev(0); | 307 | dev = alloc_ei_netdev(); |
308 | if (!dev) | 308 | if (!dev) |
309 | return ERR_PTR(-ENOMEM); | 309 | return ERR_PTR(-ENOMEM); |
310 | 310 | ||
@@ -478,6 +478,20 @@ void cleanup_module(void) | |||
478 | 478 | ||
479 | #endif /* MODULE */ | 479 | #endif /* MODULE */ |
480 | 480 | ||
481 | static const struct net_device_ops mac8390_netdev_ops = { | ||
482 | .ndo_open = mac8390_open, | ||
483 | .ndo_stop = mac8390_close, | ||
484 | .ndo_start_xmit = ei_start_xmit, | ||
485 | .ndo_tx_timeout = ei_tx_timeout, | ||
486 | .ndo_get_stats = ei_get_stats, | ||
487 | .ndo_set_multicast_list = ei_set_multicast_list, | ||
488 | .ndo_validate_addr = eth_validate_addr, | ||
489 | .ndo_change_mtu = eth_change_mtu, | ||
490 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
491 | .ndo_poll_controller = ei_poll, | ||
492 | #endif | ||
493 | }; | ||
494 | |||
481 | static int __init mac8390_initdev(struct net_device * dev, struct nubus_dev * ndev, | 495 | static int __init mac8390_initdev(struct net_device * dev, struct nubus_dev * ndev, |
482 | enum mac8390_type type) | 496 | enum mac8390_type type) |
483 | { | 497 | { |
@@ -503,11 +517,7 @@ static int __init mac8390_initdev(struct net_device * dev, struct nubus_dev * nd | |||
503 | int access_bitmode = 0; | 517 | int access_bitmode = 0; |
504 | 518 | ||
505 | /* Now fill in our stuff */ | 519 | /* Now fill in our stuff */ |
506 | dev->open = &mac8390_open; | 520 | dev->netdev_ops = &mac8390_netdev_ops; |
507 | dev->stop = &mac8390_close; | ||
508 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
509 | dev->poll_controller = __ei_poll; | ||
510 | #endif | ||
511 | 521 | ||
512 | /* GAR, ei_status is actually a macro even though it looks global */ | 522 | /* GAR, ei_status is actually a macro even though it looks global */ |
513 | ei_status.name = cardname[type]; | 523 | ei_status.name = cardname[type]; |