From: Arnaldo Carvalho de Melo Date: Sun, 25 Feb 2007 02:12:42 +0000 (-0800) Subject: [XFRM_TUNNEL]: Reload header pointer after pskb_may_pull/pskb_expand_head X-Git-Tag: v2.6.21-rc2~38^2~1 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e4396b544fa5c85e3c263e0bc92b0743a24ba818;p=karo-tx-linux.git [XFRM_TUNNEL]: Reload header pointer after pskb_may_pull/pskb_expand_head Please consider applying, this was found on your latest net-2.6 tree while playing around with that ip_hdr() + turn skb->nh/h/mac pointers as offsets on 64 bits idea :-) Signed-off-by: Arnaldo Carvalho de Melo Signed-off-by: David S. Miller --- diff --git a/net/ipv4/xfrm4_mode_tunnel.c b/net/ipv4/xfrm4_mode_tunnel.c index e1cab33fdad1..ceb4376f572a 100644 --- a/net/ipv4/xfrm4_mode_tunnel.c +++ b/net/ipv4/xfrm4_mode_tunnel.c @@ -111,6 +111,7 @@ static int xfrm4_tunnel_input(struct xfrm_state *x, struct sk_buff *skb) (err = pskb_expand_head(skb, 0, 0, GFP_ATOMIC))) goto out; + iph = skb->nh.iph; if (iph->protocol == IPPROTO_IPIP) { if (x->props.flags & XFRM_STATE_DECAP_DSCP) ipv4_copy_dscp(iph, skb->h.ipiph);