]> Git Repo - linux.git/blobdiff - net/core/gro.c
net: allow gro_max_size to exceed 65536
[linux.git] / net / core / gro.c
index 78110edf5d4b36d2fa6f8a2676096efe0112aa0e..b4190eb084672fb4f2be8b437eccb4e8507ff63f 100644 (file)
@@ -167,6 +167,14 @@ int skb_gro_receive(struct sk_buff *p, struct sk_buff *skb)
        if (unlikely(p->len + len >= gro_max_size || NAPI_GRO_CB(skb)->flush))
                return -E2BIG;
 
+       if (unlikely(p->len + len >= GRO_LEGACY_MAX_SIZE)) {
+               if (p->protocol != htons(ETH_P_IPV6) ||
+                   skb_headroom(p) < sizeof(struct hop_jumbo_hdr) ||
+                   ipv6_hdr(p)->nexthdr != IPPROTO_TCP ||
+                   p->encapsulation)
+                       return -E2BIG;
+       }
+
        lp = NAPI_GRO_CB(p)->last;
        pinfo = skb_shinfo(lp);
 
This page took 0.031338 seconds and 4 git commands to generate.