diff options
author | Jerry Chu <hkchu@google.com> | 2014-07-15 00:54:46 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-07-16 23:45:26 +0200 |
commit | c3caf1192f904de2f1381211f564537235d50de3 (patch) | |
tree | 06fb9dd668fe6f670ef5de68af8c2fe881e8029b /net/ipv4/gre_offload.c | |
parent | Merge tag 'for-linus-20140716' of git://git.infradead.org/linux-mtd (diff) | |
download | linux-c3caf1192f904de2f1381211f564537235d50de3.tar.xz linux-c3caf1192f904de2f1381211f564537235d50de3.zip |
net-gre-gro: Fix a bug that breaks the forwarding path
Fixed a bug that was introduced by my GRE-GRO patch
(bf5a755f5e9186406bbf50f4087100af5bd68e40 net-gre-gro: Add GRE
support to the GRO stack) that breaks the forwarding path
because various GSO related fields were not set. The bug will
cause on the egress path either the GSO code to fail, or a
GRE-TSO capable (NETIF_F_GSO_GRE) NICs to choke. The following
fix has been tested for both cases.
Signed-off-by: H.K. Jerry Chu <hkchu@google.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.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/ipv4/gre_offload.c b/net/ipv4/gre_offload.c index eb92deb12666..f0bdd47bbbcb 100644 --- a/net/ipv4/gre_offload.c +++ b/net/ipv4/gre_offload.c @@ -263,6 +263,9 @@ static int gre_gro_complete(struct sk_buff *skb, int nhoff) int err = -ENOENT; __be16 type; + skb->encapsulation = 1; + skb_shinfo(skb)->gso_type = SKB_GSO_GRE; + type = greh->protocol; if (greh->flags & GRE_KEY) grehlen += GRE_HEADER_SECTION; |