Commit fc59f9a3 authored by Herbert Xu's avatar Herbert Xu Committed by David S. Miller

gro: Restore correct value to gso_size

Since everybody has been focusing on baremetal GRO performance
no one noticed when I added a bug that zapped gso_size for all
GRO packets.  This only gets picked up when you forward the skb
out of an interface.

Thanks to Mark Wagner for noticing this bug when testing kvm.
Reported-by: default avatarMark Wagner <mwagner@redhat.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ce8632ba
...@@ -2328,8 +2328,10 @@ static int napi_gro_complete(struct sk_buff *skb) ...@@ -2328,8 +2328,10 @@ static int napi_gro_complete(struct sk_buff *skb)
struct list_head *head = &ptype_base[ntohs(type) & PTYPE_HASH_MASK]; struct list_head *head = &ptype_base[ntohs(type) & PTYPE_HASH_MASK];
int err = -ENOENT; int err = -ENOENT;
if (NAPI_GRO_CB(skb)->count == 1) if (NAPI_GRO_CB(skb)->count == 1) {
skb_shinfo(skb)->gso_size = 0;
goto out; goto out;
}
rcu_read_lock(); rcu_read_lock();
list_for_each_entry_rcu(ptype, head, list) { list_for_each_entry_rcu(ptype, head, list) {
...@@ -2348,7 +2350,6 @@ static int napi_gro_complete(struct sk_buff *skb) ...@@ -2348,7 +2350,6 @@ static int napi_gro_complete(struct sk_buff *skb)
} }
out: out:
skb_shinfo(skb)->gso_size = 0;
return netif_receive_skb(skb); return netif_receive_skb(skb);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment