diff options
author | David Stevens <dlstevens@us.ibm.com> | 2010-12-17 11:42:42 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-19 20:22:23 -0800 |
commit | ad0081e43af6de3fecf308b0d098f9611835766b (patch) | |
tree | 76f25d2666ed36e4668bd0897a4de23bd601c7b8 /include/net | |
parent | 4b8fe66300acb2fba8b16d62606e0d30204022fc (diff) |
ipv6: Fragment locally generated tunnel-mode IPSec6 packets as needed.
This patch modifies IPsec6 to fragment IPv6 packets that are
locally generated as needed.
This version of the patch only fragments in tunnel mode, so that fragment
headers will not be obscured by ESP in transport mode.
Signed-off-by: David L Stevens <dlstevens@us.ibm.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/ip6_route.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/net/ip6_route.h b/include/net/ip6_route.h index 278312c95f9..2ab926860cd 100644 --- a/include/net/ip6_route.h +++ b/include/net/ip6_route.h @@ -164,5 +164,15 @@ static inline int ipv6_unicast_destination(struct sk_buff *skb) return rt->rt6i_flags & RTF_LOCAL; } +int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *)); + +static inline int ip6_skb_dst_mtu(struct sk_buff *skb) +{ + struct ipv6_pinfo *np = skb->sk ? inet6_sk(skb->sk) : NULL; + + return (np && np->pmtudisc == IPV6_PMTUDISC_PROBE) ? + skb_dst(skb)->dev->mtu : dst_mtu(skb_dst(skb)); +} + #endif #endif |