From: Jiri Pirko Date: Fri, 19 Aug 2011 04:29:27 +0000 (-0700) Subject: vlan: reset headers on accel emulation path X-Git-Tag: firefly_0821_release~7541^2~2686 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b082a5631a746b494553f7c72b387cb625a1674a;p=firefly-linux-kernel-4.4.55.git vlan: reset headers on accel emulation path [ Upstream commit c5114cd59d2664f258b0d021d79b1532d94bdc2b ] It's after all necessary to do reset headers here. The reason is we cannot depend that it gets reseted in __netif_receive_skb once skb is reinjected. For incoming vlanids without vlan_dev, vlan_do_receive() returns false with skb != NULL and __netif_reveive_skb continues, skb is not reinjected. This might be good material for 3.0-stable as well Reported-by: Mike Auty Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c index fcc684678af6..27263fb15642 100644 --- a/net/8021q/vlan_core.c +++ b/net/8021q/vlan_core.c @@ -171,6 +171,8 @@ struct sk_buff *vlan_untag(struct sk_buff *skb) if (unlikely(!skb)) goto err_free; + skb_reset_network_header(skb); + skb_reset_transport_header(skb); return skb; err_free: