summaryrefslogtreecommitdiffstats
path: root/net/ipv4/gre_offload.c
diff options
context:
space:
mode:
authorAlexander Duyck2016-02-06 00:27:55 +0100
committerDavid S. Miller2016-02-11 14:55:34 +0100
commitddff00d420432d54eb420bb33034bb8e22dd2543 (patch)
treefa2c13ae3708f32259da676c3b2c750e7ead8572 /net/ipv4/gre_offload.c
parentnet: Store checksum result for offloaded GSO checksums (diff)
downloadkernel-qcow2-linux-ddff00d420432d54eb420bb33034bb8e22dd2543.tar.gz
kernel-qcow2-linux-ddff00d420432d54eb420bb33034bb8e22dd2543.tar.xz
kernel-qcow2-linux-ddff00d420432d54eb420bb33034bb8e22dd2543.zip
net: Move skb_has_shared_frag check out of GRE code and into segmentation
The call skb_has_shared_frag is used in the GRE path and skb_checksum_help to verify that no frags can be modified by an external entity. This check really doesn't belong in the GRE path but in the skb_segment function itself. This way any protocol that might be segmented will be performing this check before attempting to offload a checksum to software. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Acked-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/gre_offload.c')
-rw-r--r--net/ipv4/gre_offload.c11
1 files changed, 0 insertions, 11 deletions
diff --git a/net/ipv4/gre_offload.c b/net/ipv4/gre_offload.c
index 02cb1a416c7d..35a8dd35ed4e 100644
--- a/net/ipv4/gre_offload.c
+++ b/net/ipv4/gre_offload.c
@@ -83,17 +83,6 @@ static struct sk_buff *gre_gso_segment(struct sk_buff *skb,
if (csum) {
__be32 *pcsum;
- if (skb_has_shared_frag(skb)) {
- int err;
-
- err = __skb_linearize(skb);
- if (err) {
- kfree_skb_list(segs);
- segs = ERR_PTR(err);
- goto out;
- }
- }
-
skb_reset_transport_header(skb);
greh = (struct gre_base_hdr *)