diff options
author | David S. Miller <davem@davemloft.net> | 2010-07-27 21:01:35 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-07-27 21:01:35 -0700 |
commit | bb7e95c8fd859922c6cf3ebbb3a8546007df1748 (patch) | |
tree | 58b54c6306ba168b76f25cc6dc9a2d1d2eb830a7 /net/core/skbuff.c | |
parent | b8bc0421ab7f83712a0a8ef7eb05fa73ec53c027 (diff) | |
parent | 5447080cfa3c77154498dfbf225367ac85b4c2b5 (diff) | |
download | talos-op-linux-bb7e95c8fd859922c6cf3ebbb3a8546007df1748.tar.gz talos-op-linux-bb7e95c8fd859922c6cf3ebbb3a8546007df1748.zip |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
drivers/net/bnx2x_main.c
Merge bnx2x bug fixes in by hand... :-/
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/skbuff.c')
-rw-r--r-- | net/core/skbuff.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 7da58a25ad92..3a2513f0d0c3 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c @@ -843,7 +843,9 @@ int pskb_expand_head(struct sk_buff *skb, int nhead, int ntail, skb->network_header += off; if (skb_mac_header_was_set(skb)) skb->mac_header += off; - skb->csum_start += nhead; + /* Only adjust this if it actually is csum_start rather than csum */ + if (skb->ip_summed == CHECKSUM_PARTIAL) + skb->csum_start += nhead; skb->cloned = 0; skb->hdr_len = 0; skb->nohdr = 0; @@ -930,7 +932,8 @@ struct sk_buff *skb_copy_expand(const struct sk_buff *skb, copy_skb_header(n, skb); off = newheadroom - oldheadroom; - n->csum_start += off; + if (n->ip_summed == CHECKSUM_PARTIAL) + n->csum_start += off; #ifdef NET_SKBUFF_DATA_USES_OFFSET n->transport_header += off; n->network_header += off; |