ipv4: Don't update the pmtu on mtu locked routes
authorSteffen Klassert <steffen.klassert@secunet.com>
Wed, 16 Jan 2013 20:58:10 +0000 (20:58 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 17 Jan 2013 08:39:36 +0000 (03:39 -0500)
Routes with locked mtu should not use learned pmtu informations,
so do not update the pmtu on these routes.

Reported-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/route.c

index 6e4a89c..259cbee 100644 (file)
@@ -912,6 +912,9 @@ static void __ip_rt_update_pmtu(struct rtable *rt, struct flowi4 *fl4, u32 mtu)
        struct dst_entry *dst = &rt->dst;
        struct fib_result res;
 
+       if (dst_metric_locked(dst, RTAX_MTU))
+               return;
+
        if (dst->dev->mtu < mtu)
                return;