diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/firewire/net.c | 2 | ||||
-rw-r--r-- | drivers/net/bonding/bond_main.c | 2 | ||||
-rw-r--r-- | drivers/net/can/vcan.c | 2 | ||||
-rw-r--r-- | drivers/net/dummy.c | 22 | ||||
-rw-r--r-- | drivers/net/eql.c | 4 | ||||
-rw-r--r-- | drivers/net/ifb.c | 9 | ||||
-rw-r--r-- | drivers/net/macvlan.c | 3 | ||||
-rw-r--r-- | drivers/net/ppp_generic.c | 2 | ||||
-rw-r--r-- | drivers/net/slip.c | 2 | ||||
-rw-r--r-- | drivers/net/tun.c | 2 | ||||
-rw-r--r-- | drivers/net/veth.c | 2 | ||||
-rw-r--r-- | drivers/net/virtio_net.c | 2 |
12 files changed, 26 insertions, 28 deletions
diff --git a/drivers/firewire/net.c b/drivers/firewire/net.c index a42209a73aed..d923d1dc458f 100644 --- a/drivers/firewire/net.c +++ b/drivers/firewire/net.c | |||
@@ -1188,7 +1188,7 @@ static int fwnet_stop(struct net_device *net) | |||
1188 | return 0; | 1188 | return 0; |
1189 | } | 1189 | } |
1190 | 1190 | ||
1191 | static int fwnet_tx(struct sk_buff *skb, struct net_device *net) | 1191 | static netdev_tx_t fwnet_tx(struct sk_buff *skb, struct net_device *net) |
1192 | { | 1192 | { |
1193 | struct fwnet_header hdr_buf; | 1193 | struct fwnet_header hdr_buf; |
1194 | struct fwnet_device *dev = netdev_priv(net); | 1194 | struct fwnet_device *dev = netdev_priv(net); |
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index 7c0e0bded15e..a7e731f8a0da 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -4450,7 +4450,7 @@ static void bond_set_xmit_hash_policy(struct bonding *bond) | |||
4450 | } | 4450 | } |
4451 | } | 4451 | } |
4452 | 4452 | ||
4453 | static int bond_start_xmit(struct sk_buff *skb, struct net_device *dev) | 4453 | static netdev_tx_t bond_start_xmit(struct sk_buff *skb, struct net_device *dev) |
4454 | { | 4454 | { |
4455 | const struct bonding *bond = netdev_priv(dev); | 4455 | const struct bonding *bond = netdev_priv(dev); |
4456 | 4456 | ||
diff --git a/drivers/net/can/vcan.c b/drivers/net/can/vcan.c index a10c1d7b3b0a..6971f6cd37fa 100644 --- a/drivers/net/can/vcan.c +++ b/drivers/net/can/vcan.c | |||
@@ -83,7 +83,7 @@ static void vcan_rx(struct sk_buff *skb, struct net_device *dev) | |||
83 | netif_rx(skb); | 83 | netif_rx(skb); |
84 | } | 84 | } |
85 | 85 | ||
86 | static int vcan_tx(struct sk_buff *skb, struct net_device *dev) | 86 | static netdev_tx_t vcan_tx(struct sk_buff *skb, struct net_device *dev) |
87 | { | 87 | { |
88 | struct net_device_stats *stats = &dev->stats; | 88 | struct net_device_stats *stats = &dev->stats; |
89 | int loop; | 89 | int loop; |
diff --git a/drivers/net/dummy.c b/drivers/net/dummy.c index 713ce6c532c5..37dcfdc63456 100644 --- a/drivers/net/dummy.c +++ b/drivers/net/dummy.c | |||
@@ -39,8 +39,6 @@ | |||
39 | 39 | ||
40 | static int numdummies = 1; | 40 | static int numdummies = 1; |
41 | 41 | ||
42 | static int dummy_xmit(struct sk_buff *skb, struct net_device *dev); | ||
43 | |||
44 | static int dummy_set_address(struct net_device *dev, void *p) | 42 | static int dummy_set_address(struct net_device *dev, void *p) |
45 | { | 43 | { |
46 | struct sockaddr *sa = p; | 44 | struct sockaddr *sa = p; |
@@ -57,6 +55,16 @@ static void set_multicast_list(struct net_device *dev) | |||
57 | { | 55 | { |
58 | } | 56 | } |
59 | 57 | ||
58 | |||
59 | static netdev_tx_t dummy_xmit(struct sk_buff *skb, struct net_device *dev) | ||
60 | { | ||
61 | dev->stats.tx_packets++; | ||
62 | dev->stats.tx_bytes += skb->len; | ||
63 | |||
64 | dev_kfree_skb(skb); | ||
65 | return NETDEV_TX_OK; | ||
66 | } | ||
67 | |||
60 | static const struct net_device_ops dummy_netdev_ops = { | 68 | static const struct net_device_ops dummy_netdev_ops = { |
61 | .ndo_start_xmit = dummy_xmit, | 69 | .ndo_start_xmit = dummy_xmit, |
62 | .ndo_validate_addr = eth_validate_addr, | 70 | .ndo_validate_addr = eth_validate_addr, |
@@ -78,16 +86,6 @@ static void dummy_setup(struct net_device *dev) | |||
78 | dev->flags &= ~IFF_MULTICAST; | 86 | dev->flags &= ~IFF_MULTICAST; |
79 | random_ether_addr(dev->dev_addr); | 87 | random_ether_addr(dev->dev_addr); |
80 | } | 88 | } |
81 | |||
82 | static int dummy_xmit(struct sk_buff *skb, struct net_device *dev) | ||
83 | { | ||
84 | dev->stats.tx_packets++; | ||
85 | dev->stats.tx_bytes += skb->len; | ||
86 | |||
87 | dev_kfree_skb(skb); | ||
88 | return NETDEV_TX_OK; | ||
89 | } | ||
90 | |||
91 | static int dummy_validate(struct nlattr *tb[], struct nlattr *data[]) | 89 | static int dummy_validate(struct nlattr *tb[], struct nlattr *data[]) |
92 | { | 90 | { |
93 | if (tb[IFLA_ADDRESS]) { | 91 | if (tb[IFLA_ADDRESS]) { |
diff --git a/drivers/net/eql.c b/drivers/net/eql.c index c0e69c5cae84..d4d9a3eda695 100644 --- a/drivers/net/eql.c +++ b/drivers/net/eql.c | |||
@@ -127,7 +127,7 @@ | |||
127 | static int eql_open(struct net_device *dev); | 127 | static int eql_open(struct net_device *dev); |
128 | static int eql_close(struct net_device *dev); | 128 | static int eql_close(struct net_device *dev); |
129 | static int eql_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd); | 129 | static int eql_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd); |
130 | static int eql_slave_xmit(struct sk_buff *skb, struct net_device *dev); | 130 | static netdev_tx_t eql_slave_xmit(struct sk_buff *skb, struct net_device *dev); |
131 | 131 | ||
132 | #define eql_is_slave(dev) ((dev->flags & IFF_SLAVE) == IFF_SLAVE) | 132 | #define eql_is_slave(dev) ((dev->flags & IFF_SLAVE) == IFF_SLAVE) |
133 | #define eql_is_master(dev) ((dev->flags & IFF_MASTER) == IFF_MASTER) | 133 | #define eql_is_master(dev) ((dev->flags & IFF_MASTER) == IFF_MASTER) |
@@ -325,7 +325,7 @@ static slave_t *__eql_schedule_slaves(slave_queue_t *queue) | |||
325 | return best_slave; | 325 | return best_slave; |
326 | } | 326 | } |
327 | 327 | ||
328 | static int eql_slave_xmit(struct sk_buff *skb, struct net_device *dev) | 328 | static netdev_tx_t eql_slave_xmit(struct sk_buff *skb, struct net_device *dev) |
329 | { | 329 | { |
330 | equalizer_t *eql = netdev_priv(dev); | 330 | equalizer_t *eql = netdev_priv(dev); |
331 | slave_t *slave; | 331 | slave_t *slave; |
diff --git a/drivers/net/ifb.c b/drivers/net/ifb.c index 0a79b4517804..801f088c134f 100644 --- a/drivers/net/ifb.c +++ b/drivers/net/ifb.c | |||
@@ -59,7 +59,7 @@ struct ifb_private { | |||
59 | static int numifbs = 2; | 59 | static int numifbs = 2; |
60 | 60 | ||
61 | static void ri_tasklet(unsigned long dev); | 61 | static void ri_tasklet(unsigned long dev); |
62 | static int ifb_xmit(struct sk_buff *skb, struct net_device *dev); | 62 | static netdev_tx_t ifb_xmit(struct sk_buff *skb, struct net_device *dev); |
63 | static int ifb_open(struct net_device *dev); | 63 | static int ifb_open(struct net_device *dev); |
64 | static int ifb_close(struct net_device *dev); | 64 | static int ifb_close(struct net_device *dev); |
65 | 65 | ||
@@ -160,11 +160,10 @@ static void ifb_setup(struct net_device *dev) | |||
160 | random_ether_addr(dev->dev_addr); | 160 | random_ether_addr(dev->dev_addr); |
161 | } | 161 | } |
162 | 162 | ||
163 | static int ifb_xmit(struct sk_buff *skb, struct net_device *dev) | 163 | static netdev_tx_t ifb_xmit(struct sk_buff *skb, struct net_device *dev) |
164 | { | 164 | { |
165 | struct ifb_private *dp = netdev_priv(dev); | 165 | struct ifb_private *dp = netdev_priv(dev); |
166 | struct net_device_stats *stats = &dev->stats; | 166 | struct net_device_stats *stats = &dev->stats; |
167 | int ret = NETDEV_TX_OK; | ||
168 | u32 from = G_TC_FROM(skb->tc_verd); | 167 | u32 from = G_TC_FROM(skb->tc_verd); |
169 | 168 | ||
170 | stats->rx_packets++; | 169 | stats->rx_packets++; |
@@ -173,7 +172,7 @@ static int ifb_xmit(struct sk_buff *skb, struct net_device *dev) | |||
173 | if (!(from & (AT_INGRESS|AT_EGRESS)) || !skb->iif) { | 172 | if (!(from & (AT_INGRESS|AT_EGRESS)) || !skb->iif) { |
174 | dev_kfree_skb(skb); | 173 | dev_kfree_skb(skb); |
175 | stats->rx_dropped++; | 174 | stats->rx_dropped++; |
176 | return ret; | 175 | return NETDEV_TX_OK; |
177 | } | 176 | } |
178 | 177 | ||
179 | if (skb_queue_len(&dp->rq) >= dev->tx_queue_len) { | 178 | if (skb_queue_len(&dp->rq) >= dev->tx_queue_len) { |
@@ -187,7 +186,7 @@ static int ifb_xmit(struct sk_buff *skb, struct net_device *dev) | |||
187 | tasklet_schedule(&dp->ifb_tasklet); | 186 | tasklet_schedule(&dp->ifb_tasklet); |
188 | } | 187 | } |
189 | 188 | ||
190 | return ret; | 189 | return NETDEV_TX_OK; |
191 | } | 190 | } |
192 | 191 | ||
193 | static int ifb_close(struct net_device *dev) | 192 | static int ifb_close(struct net_device *dev) |
diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c index 99eed9f37c84..f893cd41580a 100644 --- a/drivers/net/macvlan.c +++ b/drivers/net/macvlan.c | |||
@@ -184,7 +184,8 @@ static struct sk_buff *macvlan_handle_frame(struct sk_buff *skb) | |||
184 | return NULL; | 184 | return NULL; |
185 | } | 185 | } |
186 | 186 | ||
187 | static int macvlan_start_xmit(struct sk_buff *skb, struct net_device *dev) | 187 | static netdev_tx_t macvlan_start_xmit(struct sk_buff *skb, |
188 | struct net_device *dev) | ||
188 | { | 189 | { |
189 | const struct macvlan_dev *vlan = netdev_priv(dev); | 190 | const struct macvlan_dev *vlan = netdev_priv(dev); |
190 | unsigned int len = skb->len; | 191 | unsigned int len = skb->len; |
diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c index 35be2e8f0c98..9bf2a6be9031 100644 --- a/drivers/net/ppp_generic.c +++ b/drivers/net/ppp_generic.c | |||
@@ -951,7 +951,7 @@ out: | |||
951 | /* | 951 | /* |
952 | * Network interface unit routines. | 952 | * Network interface unit routines. |
953 | */ | 953 | */ |
954 | static int | 954 | static netdev_tx_t |
955 | ppp_start_xmit(struct sk_buff *skb, struct net_device *dev) | 955 | ppp_start_xmit(struct sk_buff *skb, struct net_device *dev) |
956 | { | 956 | { |
957 | struct ppp *ppp = netdev_priv(dev); | 957 | struct ppp *ppp = netdev_priv(dev); |
diff --git a/drivers/net/slip.c b/drivers/net/slip.c index 899c4a2112c9..26f6ee93a064 100644 --- a/drivers/net/slip.c +++ b/drivers/net/slip.c | |||
@@ -474,7 +474,7 @@ out: | |||
474 | 474 | ||
475 | 475 | ||
476 | /* Encapsulate an IP datagram and kick it into a TTY queue. */ | 476 | /* Encapsulate an IP datagram and kick it into a TTY queue. */ |
477 | static int | 477 | static netdev_tx_t |
478 | sl_xmit(struct sk_buff *skb, struct net_device *dev) | 478 | sl_xmit(struct sk_buff *skb, struct net_device *dev) |
479 | { | 479 | { |
480 | struct slip *sl = netdev_priv(dev); | 480 | struct slip *sl = netdev_priv(dev); |
diff --git a/drivers/net/tun.c b/drivers/net/tun.c index 2533f5cf2e4b..5f7842e4d4ae 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c | |||
@@ -358,7 +358,7 @@ static int tun_net_close(struct net_device *dev) | |||
358 | } | 358 | } |
359 | 359 | ||
360 | /* Net device start xmit */ | 360 | /* Net device start xmit */ |
361 | static int tun_net_xmit(struct sk_buff *skb, struct net_device *dev) | 361 | static netdev_tx_t tun_net_xmit(struct sk_buff *skb, struct net_device *dev) |
362 | { | 362 | { |
363 | struct tun_struct *tun = netdev_priv(dev); | 363 | struct tun_struct *tun = netdev_priv(dev); |
364 | 364 | ||
diff --git a/drivers/net/veth.c b/drivers/net/veth.c index 190f784c9cfe..d1941cdff62b 100644 --- a/drivers/net/veth.c +++ b/drivers/net/veth.c | |||
@@ -148,7 +148,7 @@ static struct ethtool_ops veth_ethtool_ops = { | |||
148 | * xmit | 148 | * xmit |
149 | */ | 149 | */ |
150 | 150 | ||
151 | static int veth_xmit(struct sk_buff *skb, struct net_device *dev) | 151 | static netdev_tx_t veth_xmit(struct sk_buff *skb, struct net_device *dev) |
152 | { | 152 | { |
153 | struct net_device *rcv = NULL; | 153 | struct net_device *rcv = NULL; |
154 | struct veth_priv *priv, *rcv_priv; | 154 | struct veth_priv *priv, *rcv_priv; |
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index a6f903f00924..31279c4c02c2 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c | |||
@@ -519,7 +519,7 @@ static void xmit_tasklet(unsigned long data) | |||
519 | netif_tx_unlock_bh(vi->dev); | 519 | netif_tx_unlock_bh(vi->dev); |
520 | } | 520 | } |
521 | 521 | ||
522 | static int start_xmit(struct sk_buff *skb, struct net_device *dev) | 522 | static netdev_tx_t start_xmit(struct sk_buff *skb, struct net_device *dev) |
523 | { | 523 | { |
524 | struct virtnet_info *vi = netdev_priv(dev); | 524 | struct virtnet_info *vi = netdev_priv(dev); |
525 | 525 | ||