]> git.baikalelectronics.ru Git - kernel.git/commit
ipv4: Handle PMTU in all ICMP error handlers.
authorDavid S. Miller <davem@davemloft.net>
Fri, 15 Jun 2012 05:21:46 +0000 (22:21 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Jun 2012 05:22:07 +0000 (22:22 -0700)
commit5c56eddbaf85320b10ad396a0077a3ba32f3f518
treeb45113cce1bdfc4be92a856700690a253f1bb088
parent30263659417fe66d803a3b7bda51a0791c3e9d1e
ipv4: Handle PMTU in all ICMP error handlers.

With ip_rt_frag_needed() removed, we have to explicitly update PMTU
information in every ICMP error handler.

Create two helper functions to facilitate this.

1) ipv4_sk_update_pmtu()

   This updates the PMTU when we have a socket context to
   work with.

2) ipv4_update_pmtu()

   Raw version, used when no socket context is available.  For this
   interface, we essentially just pass in explicit arguments for
   the flow identity information we would have extracted from the
   socket.

   And you'll notice that ipv4_sk_update_pmtu() is simply implemented
   in terms of ipv4_update_pmtu()

Note that __ip_route_output_key() is used, rather than something like
ip_route_output_flow() or ip_route_output_key().  This is because we
absolutely do not want to end up with a route that does IPSEC
encapsulation and the like.  Instead, we only want the route that
would get us to the node described by the outermost IP header.

Reported-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/route.h
net/ipv4/ah4.c
net/ipv4/esp4.c
net/ipv4/ip_gre.c
net/ipv4/ipcomp.c
net/ipv4/ipip.c
net/ipv4/ping.c
net/ipv4/raw.c
net/ipv4/route.c
net/ipv4/udp.c
net/ipv6/sit.c