aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/mip6.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6/mip6.c')
-rw-r--r--net/ipv6/mip6.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/ipv6/mip6.c b/net/ipv6/mip6.c
index 85202891644e..f0288e92fb52 100644
--- a/net/ipv6/mip6.c
+++ b/net/ipv6/mip6.c
@@ -92,10 +92,10 @@ int mip6_mh_filter(struct sock *sk, struct sk_buff *skb)
92 92
93 if (!pskb_may_pull(skb, (skb_transport_offset(skb)) + 8) || 93 if (!pskb_may_pull(skb, (skb_transport_offset(skb)) + 8) ||
94 !pskb_may_pull(skb, (skb_transport_offset(skb) + 94 !pskb_may_pull(skb, (skb_transport_offset(skb) +
95 ((skb->h.raw[1] + 1) << 3)))) 95 ((skb_transport_header(skb)[1] + 1) << 3))))
96 return -1; 96 return -1;
97 97
98 mh = (struct ip6_mh *)skb->h.raw; 98 mh = (struct ip6_mh *)skb_transport_header(skb);
99 99
100 if (mh->ip6mh_hdrlen < mip6_mh_len(mh->ip6mh_type)) { 100 if (mh->ip6mh_hdrlen < mip6_mh_len(mh->ip6mh_type)) {
101 LIMIT_NETDEBUG(KERN_DEBUG "mip6: MH message too short: %d vs >=%d\n", 101 LIMIT_NETDEBUG(KERN_DEBUG "mip6: MH message too short: %d vs >=%d\n",
@@ -158,7 +158,7 @@ static int mip6_destopt_output(struct xfrm_state *x, struct sk_buff *skb)
158 nexthdr = *skb_network_header(skb); 158 nexthdr = *skb_network_header(skb);
159 *skb_network_header(skb) = IPPROTO_DSTOPTS; 159 *skb_network_header(skb) = IPPROTO_DSTOPTS;
160 160
161 dstopt = (struct ipv6_destopt_hdr *)skb->h.raw; 161 dstopt = (struct ipv6_destopt_hdr *)skb_transport_header(skb);
162 dstopt->nexthdr = nexthdr; 162 dstopt->nexthdr = nexthdr;
163 163
164 hao = mip6_padn((char *)(dstopt + 1), 164 hao = mip6_padn((char *)(dstopt + 1),
@@ -370,7 +370,7 @@ static int mip6_rthdr_output(struct xfrm_state *x, struct sk_buff *skb)
370 nexthdr = *skb_network_header(skb); 370 nexthdr = *skb_network_header(skb);
371 *skb_network_header(skb) = IPPROTO_ROUTING; 371 *skb_network_header(skb) = IPPROTO_ROUTING;
372 372
373 rt2 = (struct rt2_hdr *)skb->h.raw; 373 rt2 = (struct rt2_hdr *)skb_transport_header(skb);
374 rt2->rt_hdr.nexthdr = nexthdr; 374 rt2->rt_hdr.nexthdr = nexthdr;
375 rt2->rt_hdr.hdrlen = (x->props.header_len >> 3) - 1; 375 rt2->rt_hdr.hdrlen = (x->props.header_len >> 3) - 1;
376 rt2->rt_hdr.type = IPV6_SRCRT_TYPE_2; 376 rt2->rt_hdr.type = IPV6_SRCRT_TYPE_2;