Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm
[linux] / net / ipv6 / xfrm6_mode_tunnel.c
index bb935a3..de1b0b8 100644 (file)
@@ -92,7 +92,8 @@ static int xfrm6_mode_tunnel_input(struct xfrm_state *x, struct sk_buff *skb)
 
        skb_reset_network_header(skb);
        skb_mac_header_rebuild(skb);
-       eth_hdr(skb)->h_proto = skb->protocol;
+       if (skb->mac_len)
+               eth_hdr(skb)->h_proto = skb->protocol;
 
        err = 0;