diff options
Diffstat (limited to 'net/ipv6/esp6.c')
-rw-r--r-- | net/ipv6/esp6.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/net/ipv6/esp6.c b/net/ipv6/esp6.c index db1521fcda5b..6dc7fd353ef5 100644 --- a/net/ipv6/esp6.c +++ b/net/ipv6/esp6.c | |||
@@ -39,6 +39,7 @@ | |||
39 | #include <linux/random.h> | 39 | #include <linux/random.h> |
40 | #include <linux/slab.h> | 40 | #include <linux/slab.h> |
41 | #include <linux/spinlock.h> | 41 | #include <linux/spinlock.h> |
42 | #include <net/ip6_route.h> | ||
42 | #include <net/icmp.h> | 43 | #include <net/icmp.h> |
43 | #include <net/ipv6.h> | 44 | #include <net/ipv6.h> |
44 | #include <net/protocol.h> | 45 | #include <net/protocol.h> |
@@ -433,15 +434,19 @@ static void esp6_err(struct sk_buff *skb, struct inet6_skb_parm *opt, | |||
433 | struct xfrm_state *x; | 434 | struct xfrm_state *x; |
434 | 435 | ||
435 | if (type != ICMPV6_DEST_UNREACH && | 436 | if (type != ICMPV6_DEST_UNREACH && |
436 | type != ICMPV6_PKT_TOOBIG) | 437 | type != ICMPV6_PKT_TOOBIG && |
438 | type != NDISC_REDIRECT) | ||
437 | return; | 439 | return; |
438 | 440 | ||
439 | x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr, | 441 | x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr, |
440 | esph->spi, IPPROTO_ESP, AF_INET6); | 442 | esph->spi, IPPROTO_ESP, AF_INET6); |
441 | if (!x) | 443 | if (!x) |
442 | return; | 444 | return; |
443 | pr_debug("pmtu discovery on SA ESP/%08x/%pI6\n", | 445 | |
444 | ntohl(esph->spi), &iph->daddr); | 446 | if (type == NDISC_REDIRECT) |
447 | ip6_redirect(skb, net, 0, 0); | ||
448 | else | ||
449 | ip6_update_pmtu(skb, net, info, 0, 0); | ||
445 | xfrm_state_put(x); | 450 | xfrm_state_put(x); |
446 | } | 451 | } |
447 | 452 | ||