diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-15 12:40:05 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-15 12:40:05 -0400 |
commit | 2ed0e21b30b53d3a94e204196e523e6c8f732b56 (patch) | |
tree | de2635426477d86338a9469ce09ba0626052288f /net/appletalk | |
parent | 0fa213310cd8fa7a51071cdcf130e26fa56e9549 (diff) | |
parent | 9cbc1cb8cd46ce1f7645b9de249b2ce8460129bb (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1244 commits)
pkt_sched: Rename PSCHED_US2NS and PSCHED_NS2US
ipv4: Fix fib_trie rebalancing
Bluetooth: Fix issue with uninitialized nsh.type in DTL-1 driver
Bluetooth: Fix Kconfig issue with RFKILL integration
PIM-SM: namespace changes
ipv4: update ARPD help text
net: use a deferred timer in rt_check_expire
ieee802154: fix kconfig bool/tristate muckup
bonding: initialization rework
bonding: use is_zero_ether_addr
bonding: network device names are case sensative
bonding: elminate bad refcount code
bonding: fix style issues
bonding: fix destructor
bonding: remove bonding read/write semaphore
bonding: initialize before registration
bonding: bond_create always called with default parameters
x_tables: Convert printk to pr_err
netfilter: conntrack: optional reliable conntrack event delivery
list_nulls: add hlist_nulls_add_head and hlist_nulls_del
...
Diffstat (limited to 'net/appletalk')
-rw-r--r-- | net/appletalk/ddp.c | 31 | ||||
-rw-r--r-- | net/appletalk/dev.c | 11 |
2 files changed, 14 insertions, 28 deletions
diff --git a/net/appletalk/ddp.c b/net/appletalk/ddp.c index d6a9243641af..b603cbacdc58 100644 --- a/net/appletalk/ddp.c +++ b/net/appletalk/ddp.c | |||
@@ -939,6 +939,7 @@ static unsigned long atalk_sum_skb(const struct sk_buff *skb, int offset, | |||
939 | int len, unsigned long sum) | 939 | int len, unsigned long sum) |
940 | { | 940 | { |
941 | int start = skb_headlen(skb); | 941 | int start = skb_headlen(skb); |
942 | struct sk_buff *frag_iter; | ||
942 | int i, copy; | 943 | int i, copy; |
943 | 944 | ||
944 | /* checksum stuff in header space */ | 945 | /* checksum stuff in header space */ |
@@ -977,26 +978,22 @@ static unsigned long atalk_sum_skb(const struct sk_buff *skb, int offset, | |||
977 | start = end; | 978 | start = end; |
978 | } | 979 | } |
979 | 980 | ||
980 | if (skb_shinfo(skb)->frag_list) { | 981 | skb_walk_frags(skb, frag_iter) { |
981 | struct sk_buff *list = skb_shinfo(skb)->frag_list; | 982 | int end; |
982 | |||
983 | for (; list; list = list->next) { | ||
984 | int end; | ||
985 | 983 | ||
986 | WARN_ON(start > offset + len); | 984 | WARN_ON(start > offset + len); |
987 | 985 | ||
988 | end = start + list->len; | 986 | end = start + frag_iter->len; |
989 | if ((copy = end - offset) > 0) { | 987 | if ((copy = end - offset) > 0) { |
990 | if (copy > len) | 988 | if (copy > len) |
991 | copy = len; | 989 | copy = len; |
992 | sum = atalk_sum_skb(list, offset - start, | 990 | sum = atalk_sum_skb(frag_iter, offset - start, |
993 | copy, sum); | 991 | copy, sum); |
994 | if ((len -= copy) == 0) | 992 | if ((len -= copy) == 0) |
995 | return sum; | 993 | return sum; |
996 | offset += copy; | 994 | offset += copy; |
997 | } | ||
998 | start = end; | ||
999 | } | 995 | } |
996 | start = end; | ||
1000 | } | 997 | } |
1001 | 998 | ||
1002 | BUG_ON(len > 0); | 999 | BUG_ON(len > 0); |
diff --git a/net/appletalk/dev.c b/net/appletalk/dev.c index 72277d70c980..6c8016f61866 100644 --- a/net/appletalk/dev.c +++ b/net/appletalk/dev.c | |||
@@ -9,21 +9,10 @@ | |||
9 | #include <linux/if_arp.h> | 9 | #include <linux/if_arp.h> |
10 | #include <linux/if_ltalk.h> | 10 | #include <linux/if_ltalk.h> |
11 | 11 | ||
12 | #ifdef CONFIG_COMPAT_NET_DEV_OPS | ||
13 | static int ltalk_change_mtu(struct net_device *dev, int mtu) | ||
14 | { | ||
15 | return -EINVAL; | ||
16 | } | ||
17 | #endif | ||
18 | |||
19 | static void ltalk_setup(struct net_device *dev) | 12 | static void ltalk_setup(struct net_device *dev) |
20 | { | 13 | { |
21 | /* Fill in the fields of the device structure with localtalk-generic values. */ | 14 | /* Fill in the fields of the device structure with localtalk-generic values. */ |
22 | 15 | ||
23 | #ifdef CONFIG_COMPAT_NET_DEV_OPS | ||
24 | dev->change_mtu = ltalk_change_mtu; | ||
25 | #endif | ||
26 | |||
27 | dev->type = ARPHRD_LOCALTLK; | 16 | dev->type = ARPHRD_LOCALTLK; |
28 | dev->hard_header_len = LTALK_HLEN; | 17 | dev->hard_header_len = LTALK_HLEN; |
29 | dev->mtu = LTALK_MTU; | 18 | dev->mtu = LTALK_MTU; |