diff options
author | Ingo Molnar <mingo@elte.hu> | 2010-09-15 10:27:31 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-09-15 10:27:31 +0200 |
commit | 3aabae7d9dfaed60effe93662f02c19bafc18537 (patch) | |
tree | af94cdd69add07601d9f3f5988dfc1dc255e3886 /net/core/skbuff.c | |
parent | 79e406d7b00ab2b261ae32a59f266fd3b7af6f29 (diff) | |
parent | 57c072c7113f54f9512624d6c665db6184448782 (diff) | |
download | op-kernel-dev-3aabae7d9dfaed60effe93662f02c19bafc18537.zip op-kernel-dev-3aabae7d9dfaed60effe93662f02c19bafc18537.tar.gz |
Merge branch 'tip/perf/core' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace into perf/core
Diffstat (limited to 'net/core/skbuff.c')
-rw-r--r-- | net/core/skbuff.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 12e61e3..56ba3c4 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c @@ -2574,6 +2574,10 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int features) __copy_skb_header(nskb, skb); nskb->mac_len = skb->mac_len; + /* nskb and skb might have different headroom */ + if (nskb->ip_summed == CHECKSUM_PARTIAL) + nskb->csum_start += skb_headroom(nskb) - headroom; + skb_reset_mac_header(nskb); skb_set_network_header(nskb, skb->mac_len); nskb->transport_header = (nskb->network_header + @@ -2704,7 +2708,7 @@ int skb_gro_receive(struct sk_buff **head, struct sk_buff *skb) return -E2BIG; headroom = skb_headroom(p); - nskb = netdev_alloc_skb(p->dev, headroom + skb_gro_offset(p)); + nskb = alloc_skb(headroom + skb_gro_offset(p), GFP_ATOMIC); if (unlikely(!nskb)) return -ENOMEM; |