aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6')
-rw-r--r--net/ipv6/ip6_output.c5
-rw-r--r--net/ipv6/xfrm6_policy.c3
2 files changed, 5 insertions, 3 deletions
diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
index 150615758fdc..387030d2483c 100644
--- a/net/ipv6/ip6_output.c
+++ b/net/ipv6/ip6_output.c
@@ -1099,7 +1099,7 @@ int ip6_append_data(struct sock *sk, int getfrag(void *from, char *to,
1099 sk->sk_sndmsg_page = NULL; 1099 sk->sk_sndmsg_page = NULL;
1100 sk->sk_sndmsg_off = 0; 1100 sk->sk_sndmsg_off = 0;
1101 exthdrlen = rt->u.dst.header_len + (opt ? opt->opt_flen : 0) - 1101 exthdrlen = rt->u.dst.header_len + (opt ? opt->opt_flen : 0) -
1102 rt->u.dst.nfheader_len; 1102 rt->nfheader_len;
1103 length += exthdrlen; 1103 length += exthdrlen;
1104 transhdrlen += exthdrlen; 1104 transhdrlen += exthdrlen;
1105 } else { 1105 } else {
@@ -1114,7 +1114,8 @@ int ip6_append_data(struct sock *sk, int getfrag(void *from, char *to,
1114 1114
1115 hh_len = LL_RESERVED_SPACE(rt->u.dst.dev); 1115 hh_len = LL_RESERVED_SPACE(rt->u.dst.dev);
1116 1116
1117 fragheaderlen = sizeof(struct ipv6hdr) + rt->u.dst.nfheader_len + (opt ? opt->opt_nflen : 0); 1117 fragheaderlen = sizeof(struct ipv6hdr) + rt->nfheader_len +
1118 (opt ? opt->opt_nflen : 0);
1118 maxfraglen = ((mtu - fragheaderlen) & ~7) + fragheaderlen - sizeof(struct frag_hdr); 1119 maxfraglen = ((mtu - fragheaderlen) & ~7) + fragheaderlen - sizeof(struct frag_hdr);
1119 1120
1120 if (mtu <= sizeof(struct ipv6hdr) + IPV6_MAXPLEN) { 1121 if (mtu <= sizeof(struct ipv6hdr) + IPV6_MAXPLEN) {
diff --git a/net/ipv6/xfrm6_policy.c b/net/ipv6/xfrm6_policy.c
index 3cad3e8dc4da..5b02f0efd38e 100644
--- a/net/ipv6/xfrm6_policy.c
+++ b/net/ipv6/xfrm6_policy.c
@@ -157,7 +157,8 @@ __xfrm6_bundle_create(struct xfrm_policy *policy, struct xfrm_state **xfrm, int
157 dst_prev = dst1; 157 dst_prev = dst1;
158 158
159 if (xfrm[i]->type->flags & XFRM_TYPE_NON_FRAGMENT) 159 if (xfrm[i]->type->flags & XFRM_TYPE_NON_FRAGMENT)
160 dst->nfheader_len += xfrm[i]->props.header_len; 160 ((struct rt6_info *)dst)->nfheader_len +=
161 xfrm[i]->props.header_len;
161 header_len += xfrm[i]->props.header_len; 162 header_len += xfrm[i]->props.header_len;
162 trailer_len += xfrm[i]->props.trailer_len; 163 trailer_len += xfrm[i]->props.trailer_len;
163 164