diff options
-rw-r--r-- | drivers/net/cxgb4vf/cxgb4vf_main.c | 17 | ||||
-rw-r--r-- | drivers/staging/ft1000/ft1000-usb/ft1000_hw.c | 9 | ||||
-rw-r--r-- | drivers/staging/wlags49_h2/wl_internal.h | 7 | ||||
-rw-r--r-- | include/linux/netdevice.h | 12 | ||||
-rw-r--r-- | net/batman-adv/soft-interface.c | 16 |
5 files changed, 0 insertions, 61 deletions
diff --git a/drivers/net/cxgb4vf/cxgb4vf_main.c b/drivers/net/cxgb4vf/cxgb4vf_main.c index 8a6f8911bc55..3942a825b3dd 100644 --- a/drivers/net/cxgb4vf/cxgb4vf_main.c +++ b/drivers/net/cxgb4vf/cxgb4vf_main.c | |||
@@ -2421,7 +2421,6 @@ static int __devinit enable_msix(struct adapter *adapter) | |||
2421 | return err; | 2421 | return err; |
2422 | } | 2422 | } |
2423 | 2423 | ||
2424 | #ifdef HAVE_NET_DEVICE_OPS | ||
2425 | static const struct net_device_ops cxgb4vf_netdev_ops = { | 2424 | static const struct net_device_ops cxgb4vf_netdev_ops = { |
2426 | .ndo_open = cxgb4vf_open, | 2425 | .ndo_open = cxgb4vf_open, |
2427 | .ndo_stop = cxgb4vf_stop, | 2426 | .ndo_stop = cxgb4vf_stop, |
@@ -2437,7 +2436,6 @@ static const struct net_device_ops cxgb4vf_netdev_ops = { | |||
2437 | .ndo_poll_controller = cxgb4vf_poll_controller, | 2436 | .ndo_poll_controller = cxgb4vf_poll_controller, |
2438 | #endif | 2437 | #endif |
2439 | }; | 2438 | }; |
2440 | #endif | ||
2441 | 2439 | ||
2442 | /* | 2440 | /* |
2443 | * "Probe" a device: initialize a device and construct all kernel and driver | 2441 | * "Probe" a device: initialize a device and construct all kernel and driver |
@@ -2611,22 +2609,7 @@ static int __devinit cxgb4vf_pci_probe(struct pci_dev *pdev, | |||
2611 | if (pci_using_dac) | 2609 | if (pci_using_dac) |
2612 | netdev->features |= NETIF_F_HIGHDMA; | 2610 | netdev->features |= NETIF_F_HIGHDMA; |
2613 | 2611 | ||
2614 | #ifdef HAVE_NET_DEVICE_OPS | ||
2615 | netdev->netdev_ops = &cxgb4vf_netdev_ops; | 2612 | netdev->netdev_ops = &cxgb4vf_netdev_ops; |
2616 | #else | ||
2617 | netdev->vlan_rx_register = cxgb4vf_vlan_rx_register; | ||
2618 | netdev->open = cxgb4vf_open; | ||
2619 | netdev->stop = cxgb4vf_stop; | ||
2620 | netdev->hard_start_xmit = t4vf_eth_xmit; | ||
2621 | netdev->get_stats = cxgb4vf_get_stats; | ||
2622 | netdev->set_rx_mode = cxgb4vf_set_rxmode; | ||
2623 | netdev->do_ioctl = cxgb4vf_do_ioctl; | ||
2624 | netdev->change_mtu = cxgb4vf_change_mtu; | ||
2625 | netdev->set_mac_address = cxgb4vf_set_mac_addr; | ||
2626 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
2627 | netdev->poll_controller = cxgb4vf_poll_controller; | ||
2628 | #endif | ||
2629 | #endif | ||
2630 | SET_ETHTOOL_OPS(netdev, &cxgb4vf_ethtool_ops); | 2613 | SET_ETHTOOL_OPS(netdev, &cxgb4vf_ethtool_ops); |
2631 | 2614 | ||
2632 | /* | 2615 | /* |
diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_hw.c b/drivers/staging/ft1000/ft1000-usb/ft1000_hw.c index b0a4211f43a1..3f303ea14337 100644 --- a/drivers/staging/ft1000/ft1000-usb/ft1000_hw.c +++ b/drivers/staging/ft1000/ft1000-usb/ft1000_hw.c | |||
@@ -671,7 +671,6 @@ static int ft1000_reset_card(struct net_device *dev) | |||
671 | return TRUE; | 671 | return TRUE; |
672 | } | 672 | } |
673 | 673 | ||
674 | #ifdef HAVE_NET_DEVICE_OPS | ||
675 | static const struct net_device_ops ftnet_ops = | 674 | static const struct net_device_ops ftnet_ops = |
676 | { | 675 | { |
677 | .ndo_open = &ft1000_open, | 676 | .ndo_open = &ft1000_open, |
@@ -679,7 +678,6 @@ static const struct net_device_ops ftnet_ops = | |||
679 | .ndo_start_xmit = &ft1000_start_xmit, | 678 | .ndo_start_xmit = &ft1000_start_xmit, |
680 | .ndo_get_stats = &ft1000_netdev_stats, | 679 | .ndo_get_stats = &ft1000_netdev_stats, |
681 | }; | 680 | }; |
682 | #endif | ||
683 | 681 | ||
684 | 682 | ||
685 | //--------------------------------------------------------------------------- | 683 | //--------------------------------------------------------------------------- |
@@ -764,14 +762,7 @@ int init_ft1000_netdev(struct ft1000_device *ft1000dev) | |||
764 | 762 | ||
765 | INIT_LIST_HEAD(&pInfo->nodes.list); | 763 | INIT_LIST_HEAD(&pInfo->nodes.list); |
766 | 764 | ||
767 | #ifdef HAVE_NET_DEVICE_OPS | ||
768 | netdev->netdev_ops = &ftnet_ops; | 765 | netdev->netdev_ops = &ftnet_ops; |
769 | #else | ||
770 | netdev->hard_start_xmit = &ft1000_start_xmit; | ||
771 | netdev->get_stats = &ft1000_netdev_stats; | ||
772 | netdev->open = &ft1000_open; | ||
773 | netdev->stop = &ft1000_close; | ||
774 | #endif | ||
775 | 766 | ||
776 | ft1000dev->net = netdev; | 767 | ft1000dev->net = netdev; |
777 | 768 | ||
diff --git a/drivers/staging/wlags49_h2/wl_internal.h b/drivers/staging/wlags49_h2/wl_internal.h index cd129b3ee6c0..e86aad53b53d 100644 --- a/drivers/staging/wlags49_h2/wl_internal.h +++ b/drivers/staging/wlags49_h2/wl_internal.h | |||
@@ -990,14 +990,7 @@ struct wl_private | |||
990 | #endif // USE_WDS | 990 | #endif // USE_WDS |
991 | }; // wl_private | 991 | }; // wl_private |
992 | 992 | ||
993 | #ifdef HAVE_NETDEV_PRIV | ||
994 | #define wl_priv(dev) ((struct wl_private *) netdev_priv(dev)) | 993 | #define wl_priv(dev) ((struct wl_private *) netdev_priv(dev)) |
995 | #else | ||
996 | extern inline struct wl_private *wl_priv(struct net_device *dev) | ||
997 | { | ||
998 | return dev->priv; | ||
999 | } | ||
1000 | #endif | ||
1001 | 994 | ||
1002 | /********************************************************************/ | 995 | /********************************************************************/ |
1003 | /* Locking and synchronization functions */ | 996 | /* Locking and synchronization functions */ |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 011eb89e9582..30f17e42c304 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -60,11 +60,6 @@ struct wireless_dev; | |||
60 | #define SET_ETHTOOL_OPS(netdev,ops) \ | 60 | #define SET_ETHTOOL_OPS(netdev,ops) \ |
61 | ( (netdev)->ethtool_ops = (ops) ) | 61 | ( (netdev)->ethtool_ops = (ops) ) |
62 | 62 | ||
63 | #define HAVE_ALLOC_NETDEV /* feature macro: alloc_xxxdev | ||
64 | functions are available. */ | ||
65 | #define HAVE_FREE_NETDEV /* free_netdev() */ | ||
66 | #define HAVE_NETDEV_PRIV /* netdev_priv() */ | ||
67 | |||
68 | /* hardware address assignment types */ | 63 | /* hardware address assignment types */ |
69 | #define NET_ADDR_PERM 0 /* address is permanent (default) */ | 64 | #define NET_ADDR_PERM 0 /* address is permanent (default) */ |
70 | #define NET_ADDR_RANDOM 1 /* address is generated randomly */ | 65 | #define NET_ADDR_RANDOM 1 /* address is generated randomly */ |
@@ -313,7 +308,6 @@ struct header_ops { | |||
313 | const void *saddr, unsigned len); | 308 | const void *saddr, unsigned len); |
314 | int (*parse)(const struct sk_buff *skb, unsigned char *haddr); | 309 | int (*parse)(const struct sk_buff *skb, unsigned char *haddr); |
315 | int (*rebuild)(struct sk_buff *skb); | 310 | int (*rebuild)(struct sk_buff *skb); |
316 | #define HAVE_HEADER_CACHE | ||
317 | int (*cache)(const struct neighbour *neigh, struct hh_cache *hh); | 311 | int (*cache)(const struct neighbour *neigh, struct hh_cache *hh); |
318 | void (*cache_update)(struct hh_cache *hh, | 312 | void (*cache_update)(struct hh_cache *hh, |
319 | const struct net_device *dev, | 313 | const struct net_device *dev, |
@@ -887,7 +881,6 @@ struct netdev_tc_txq { | |||
887 | * Must return >0 or -errno if it changed dev->features itself. | 881 | * Must return >0 or -errno if it changed dev->features itself. |
888 | * | 882 | * |
889 | */ | 883 | */ |
890 | #define HAVE_NET_DEVICE_OPS | ||
891 | struct net_device_ops { | 884 | struct net_device_ops { |
892 | int (*ndo_init)(struct net_device *dev); | 885 | int (*ndo_init)(struct net_device *dev); |
893 | void (*ndo_uninit)(struct net_device *dev); | 886 | void (*ndo_uninit)(struct net_device *dev); |
@@ -1781,8 +1774,6 @@ static inline void input_queue_tail_incr_save(struct softnet_data *sd, | |||
1781 | 1774 | ||
1782 | DECLARE_PER_CPU_ALIGNED(struct softnet_data, softnet_data); | 1775 | DECLARE_PER_CPU_ALIGNED(struct softnet_data, softnet_data); |
1783 | 1776 | ||
1784 | #define HAVE_NETIF_QUEUE | ||
1785 | |||
1786 | extern void __netif_schedule(struct Qdisc *q); | 1777 | extern void __netif_schedule(struct Qdisc *q); |
1787 | 1778 | ||
1788 | static inline void netif_schedule_queue(struct netdev_queue *txq) | 1779 | static inline void netif_schedule_queue(struct netdev_queue *txq) |
@@ -2058,10 +2049,8 @@ extern void dev_kfree_skb_irq(struct sk_buff *skb); | |||
2058 | */ | 2049 | */ |
2059 | extern void dev_kfree_skb_any(struct sk_buff *skb); | 2050 | extern void dev_kfree_skb_any(struct sk_buff *skb); |
2060 | 2051 | ||
2061 | #define HAVE_NETIF_RX 1 | ||
2062 | extern int netif_rx(struct sk_buff *skb); | 2052 | extern int netif_rx(struct sk_buff *skb); |
2063 | extern int netif_rx_ni(struct sk_buff *skb); | 2053 | extern int netif_rx_ni(struct sk_buff *skb); |
2064 | #define HAVE_NETIF_RECEIVE_SKB 1 | ||
2065 | extern int netif_receive_skb(struct sk_buff *skb); | 2054 | extern int netif_receive_skb(struct sk_buff *skb); |
2066 | extern gro_result_t dev_gro_receive(struct napi_struct *napi, | 2055 | extern gro_result_t dev_gro_receive(struct napi_struct *napi, |
2067 | struct sk_buff *skb); | 2056 | struct sk_buff *skb); |
@@ -2241,7 +2230,6 @@ extern void netif_device_attach(struct net_device *dev); | |||
2241 | /* | 2230 | /* |
2242 | * Network interface message level settings | 2231 | * Network interface message level settings |
2243 | */ | 2232 | */ |
2244 | #define HAVE_NETIF_MSG 1 | ||
2245 | 2233 | ||
2246 | enum { | 2234 | enum { |
2247 | NETIF_MSG_DRV = 0x0001, | 2235 | NETIF_MSG_DRV = 0x0001, |
diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c index 3f20332e1d38..3e2f91ffa4e2 100644 --- a/net/batman-adv/soft-interface.c +++ b/net/batman-adv/soft-interface.c | |||
@@ -750,7 +750,6 @@ out: | |||
750 | return; | 750 | return; |
751 | } | 751 | } |
752 | 752 | ||
753 | #ifdef HAVE_NET_DEVICE_OPS | ||
754 | static const struct net_device_ops bat_netdev_ops = { | 753 | static const struct net_device_ops bat_netdev_ops = { |
755 | .ndo_open = interface_open, | 754 | .ndo_open = interface_open, |
756 | .ndo_stop = interface_release, | 755 | .ndo_stop = interface_release, |
@@ -760,7 +759,6 @@ static const struct net_device_ops bat_netdev_ops = { | |||
760 | .ndo_start_xmit = interface_tx, | 759 | .ndo_start_xmit = interface_tx, |
761 | .ndo_validate_addr = eth_validate_addr | 760 | .ndo_validate_addr = eth_validate_addr |
762 | }; | 761 | }; |
763 | #endif | ||
764 | 762 | ||
765 | static void interface_setup(struct net_device *dev) | 763 | static void interface_setup(struct net_device *dev) |
766 | { | 764 | { |
@@ -769,16 +767,7 @@ static void interface_setup(struct net_device *dev) | |||
769 | 767 | ||
770 | ether_setup(dev); | 768 | ether_setup(dev); |
771 | 769 | ||
772 | #ifdef HAVE_NET_DEVICE_OPS | ||
773 | dev->netdev_ops = &bat_netdev_ops; | 770 | dev->netdev_ops = &bat_netdev_ops; |
774 | #else | ||
775 | dev->open = interface_open; | ||
776 | dev->stop = interface_release; | ||
777 | dev->get_stats = interface_stats; | ||
778 | dev->set_mac_address = interface_set_mac_addr; | ||
779 | dev->change_mtu = interface_change_mtu; | ||
780 | dev->hard_start_xmit = interface_tx; | ||
781 | #endif | ||
782 | dev->destructor = free_netdev; | 771 | dev->destructor = free_netdev; |
783 | dev->tx_queue_len = 0; | 772 | dev->tx_queue_len = 0; |
784 | 773 | ||
@@ -885,13 +874,8 @@ void softif_destroy(struct net_device *soft_iface) | |||
885 | 874 | ||
886 | int softif_is_valid(const struct net_device *net_dev) | 875 | int softif_is_valid(const struct net_device *net_dev) |
887 | { | 876 | { |
888 | #ifdef HAVE_NET_DEVICE_OPS | ||
889 | if (net_dev->netdev_ops->ndo_start_xmit == interface_tx) | 877 | if (net_dev->netdev_ops->ndo_start_xmit == interface_tx) |
890 | return 1; | 878 | return 1; |
891 | #else | ||
892 | if (net_dev->hard_start_xmit == interface_tx) | ||
893 | return 1; | ||
894 | #endif | ||
895 | 879 | ||
896 | return 0; | 880 | return 0; |
897 | } | 881 | } |