aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6')
-rw-r--r--net/ipv6/ip6_input.c2
-rw-r--r--net/ipv6/ip6_output.c8
-rw-r--r--net/ipv6/ipv6_sockglue.c4
-rw-r--r--net/ipv6/netfilter/nf_conntrack_reasm.c2
-rw-r--r--net/ipv6/reassembly.c2
-rw-r--r--net/ipv6/xfrm6_mode_transport.c2
6 files changed, 10 insertions, 10 deletions
diff --git a/net/ipv6/ip6_input.c b/net/ipv6/ip6_input.c
index 9c3c787a21c1..2dd32a2ca056 100644
--- a/net/ipv6/ip6_input.c
+++ b/net/ipv6/ip6_input.c
@@ -101,7 +101,7 @@ int ipv6_rcv(struct sk_buff *skb, struct net_device *dev, struct packet_type *pt
101 if (hdr->version != 6) 101 if (hdr->version != 6)
102 goto err; 102 goto err;
103 103
104 skb->h.raw = (u8 *)(hdr + 1); 104 skb->h.raw = skb->nh.raw + sizeof(*hdr);
105 IP6CB(skb)->nhoff = offsetof(struct ipv6hdr, nexthdr); 105 IP6CB(skb)->nhoff = offsetof(struct ipv6hdr, nexthdr);
106 106
107 pkt_len = ntohs(hdr->payload_len); 107 pkt_len = ntohs(hdr->payload_len);
diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
index 1900c6226866..0f4434eff66a 100644
--- a/net/ipv6/ip6_output.c
+++ b/net/ipv6/ip6_output.c
@@ -654,7 +654,7 @@ static int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *))
654 * before previous one went down. */ 654 * before previous one went down. */
655 if (frag) { 655 if (frag) {
656 frag->ip_summed = CHECKSUM_NONE; 656 frag->ip_summed = CHECKSUM_NONE;
657 frag->h.raw = frag->data; 657 skb_reset_transport_header(frag);
658 fh = (struct frag_hdr*)__skb_push(frag, sizeof(struct frag_hdr)); 658 fh = (struct frag_hdr*)__skb_push(frag, sizeof(struct frag_hdr));
659 __skb_push(frag, hlen); 659 __skb_push(frag, hlen);
660 skb_reset_network_header(frag); 660 skb_reset_network_header(frag);
@@ -747,8 +747,8 @@ slow_path:
747 skb_reserve(frag, LL_RESERVED_SPACE(rt->u.dst.dev)); 747 skb_reserve(frag, LL_RESERVED_SPACE(rt->u.dst.dev));
748 skb_put(frag, len + hlen + sizeof(struct frag_hdr)); 748 skb_put(frag, len + hlen + sizeof(struct frag_hdr));
749 skb_reset_network_header(frag); 749 skb_reset_network_header(frag);
750 fh = (struct frag_hdr*)(frag->data + hlen); 750 fh = (struct frag_hdr *)(skb_network_header(frag) + hlen);
751 frag->h.raw = frag->data + hlen + sizeof(struct frag_hdr); 751 frag->h.raw = frag->nh.raw + hlen + sizeof(struct frag_hdr);
752 752
753 /* 753 /*
754 * Charge the memory for the fragment to any owner 754 * Charge the memory for the fragment to any owner
@@ -991,7 +991,7 @@ static inline int ip6_ufo_append_data(struct sock *sk,
991 skb_reset_network_header(skb); 991 skb_reset_network_header(skb);
992 992
993 /* initialize protocol header pointer */ 993 /* initialize protocol header pointer */
994 skb->h.raw = skb->data + fragheaderlen; 994 skb->h.raw = skb->nh.raw + fragheaderlen;
995 995
996 skb->ip_summed = CHECKSUM_PARTIAL; 996 skb->ip_summed = CHECKSUM_PARTIAL;
997 skb->csum = 0; 997 skb->csum = 0;
diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c
index d16e0fd2cd89..da930fa089c9 100644
--- a/net/ipv6/ipv6_sockglue.c
+++ b/net/ipv6/ipv6_sockglue.c
@@ -108,7 +108,7 @@ static int ipv6_gso_send_check(struct sk_buff *skb)
108 rcu_read_lock(); 108 rcu_read_lock();
109 ops = ipv6_gso_pull_exthdrs(skb, ipv6h->nexthdr); 109 ops = ipv6_gso_pull_exthdrs(skb, ipv6h->nexthdr);
110 if (likely(ops && ops->gso_send_check)) { 110 if (likely(ops && ops->gso_send_check)) {
111 skb->h.raw = skb->data; 111 skb_reset_transport_header(skb);
112 err = ops->gso_send_check(skb); 112 err = ops->gso_send_check(skb);
113 } 113 }
114 rcu_read_unlock(); 114 rcu_read_unlock();
@@ -144,7 +144,7 @@ static struct sk_buff *ipv6_gso_segment(struct sk_buff *skb, int features)
144 rcu_read_lock(); 144 rcu_read_lock();
145 ops = ipv6_gso_pull_exthdrs(skb, ipv6h->nexthdr); 145 ops = ipv6_gso_pull_exthdrs(skb, ipv6h->nexthdr);
146 if (likely(ops && ops->gso_segment)) { 146 if (likely(ops && ops->gso_segment)) {
147 skb->h.raw = skb->data; 147 skb_reset_transport_header(skb);
148 segs = ops->gso_segment(skb, features); 148 segs = ops->gso_segment(skb, features);
149 } 149 }
150 rcu_read_unlock(); 150 rcu_read_unlock();
diff --git a/net/ipv6/netfilter/nf_conntrack_reasm.c b/net/ipv6/netfilter/nf_conntrack_reasm.c
index d3fbb1f1caf5..75138cf1fa61 100644
--- a/net/ipv6/netfilter/nf_conntrack_reasm.c
+++ b/net/ipv6/netfilter/nf_conntrack_reasm.c
@@ -634,7 +634,7 @@ nf_ct_frag6_reasm(struct nf_ct_frag6_queue *fq, struct net_device *dev)
634 head->nh.raw += sizeof(struct frag_hdr); 634 head->nh.raw += sizeof(struct frag_hdr);
635 635
636 skb_shinfo(head)->frag_list = head->next; 636 skb_shinfo(head)->frag_list = head->next;
637 head->h.raw = head->data; 637 skb_reset_transport_header(head);
638 skb_push(head, head->data - skb_network_header(head)); 638 skb_push(head, head->data - skb_network_header(head));
639 atomic_sub(head->truesize, &nf_ct_frag6_mem); 639 atomic_sub(head->truesize, &nf_ct_frag6_mem);
640 640
diff --git a/net/ipv6/reassembly.c b/net/ipv6/reassembly.c
index 156a37fe3ff3..2594f0fb290d 100644
--- a/net/ipv6/reassembly.c
+++ b/net/ipv6/reassembly.c
@@ -653,7 +653,7 @@ static int ip6_frag_reasm(struct frag_queue *fq, struct sk_buff **skb_in,
653 head->nh.raw += sizeof(struct frag_hdr); 653 head->nh.raw += sizeof(struct frag_hdr);
654 654
655 skb_shinfo(head)->frag_list = head->next; 655 skb_shinfo(head)->frag_list = head->next;
656 head->h.raw = head->data; 656 skb_reset_transport_header(head);
657 skb_push(head, head->data - skb_network_header(head)); 657 skb_push(head, head->data - skb_network_header(head));
658 atomic_sub(head->truesize, &ip6_frag_mem); 658 atomic_sub(head->truesize, &ip6_frag_mem);
659 659
diff --git a/net/ipv6/xfrm6_mode_transport.c b/net/ipv6/xfrm6_mode_transport.c
index 358b60d9d912..cae6cacd58c4 100644
--- a/net/ipv6/xfrm6_mode_transport.c
+++ b/net/ipv6/xfrm6_mode_transport.c
@@ -59,7 +59,7 @@ static int xfrm6_transport_input(struct xfrm_state *x, struct sk_buff *skb)
59 } 59 }
60 ipv6_hdr(skb)->payload_len = htons(skb->len + ihl - 60 ipv6_hdr(skb)->payload_len = htons(skb->len + ihl -
61 sizeof(struct ipv6hdr)); 61 sizeof(struct ipv6hdr));
62 skb->h.raw = skb->data; 62 skb_reset_transport_header(skb);
63 return 0; 63 return 0;
64} 64}
65 65