diff options
Diffstat (limited to 'net/rose/rose_dev.c')
| -rw-r--r-- | net/rose/rose_dev.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/rose/rose_dev.c b/net/rose/rose_dev.c index 2a1bf8e119e5..7c279e2659ec 100644 --- a/net/rose/rose_dev.c +++ b/net/rose/rose_dev.c | |||
| @@ -6,7 +6,6 @@ | |||
| 6 | * | 6 | * |
| 7 | * Copyright (C) Jonathan Naylor G4KLX (g4klx@g4klx.demon.co.uk) | 7 | * Copyright (C) Jonathan Naylor G4KLX (g4klx@g4klx.demon.co.uk) |
| 8 | */ | 8 | */ |
| 9 | #include <linux/config.h> | ||
| 10 | #include <linux/module.h> | 9 | #include <linux/module.h> |
| 11 | #include <linux/proc_fs.h> | 10 | #include <linux/proc_fs.h> |
| 12 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
| @@ -60,6 +59,7 @@ static int rose_rebuild_header(struct sk_buff *skb) | |||
| 60 | struct net_device_stats *stats = netdev_priv(dev); | 59 | struct net_device_stats *stats = netdev_priv(dev); |
| 61 | unsigned char *bp = (unsigned char *)skb->data; | 60 | unsigned char *bp = (unsigned char *)skb->data; |
| 62 | struct sk_buff *skbn; | 61 | struct sk_buff *skbn; |
| 62 | unsigned int len; | ||
| 63 | 63 | ||
| 64 | #ifdef CONFIG_INET | 64 | #ifdef CONFIG_INET |
| 65 | if (arp_find(bp + 7, skb)) { | 65 | if (arp_find(bp + 7, skb)) { |
| @@ -76,6 +76,8 @@ static int rose_rebuild_header(struct sk_buff *skb) | |||
| 76 | 76 | ||
| 77 | kfree_skb(skb); | 77 | kfree_skb(skb); |
| 78 | 78 | ||
| 79 | len = skbn->len; | ||
| 80 | |||
| 79 | if (!rose_route_frame(skbn, NULL)) { | 81 | if (!rose_route_frame(skbn, NULL)) { |
| 80 | kfree_skb(skbn); | 82 | kfree_skb(skbn); |
| 81 | stats->tx_errors++; | 83 | stats->tx_errors++; |
| @@ -83,7 +85,7 @@ static int rose_rebuild_header(struct sk_buff *skb) | |||
| 83 | } | 85 | } |
| 84 | 86 | ||
| 85 | stats->tx_packets++; | 87 | stats->tx_packets++; |
| 86 | stats->tx_bytes += skbn->len; | 88 | stats->tx_bytes += len; |
| 87 | #endif | 89 | #endif |
| 88 | return 1; | 90 | return 1; |
| 89 | } | 91 | } |
