Message ID | 1300873779.3063.39.camel@edumazet-laptop |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
> Thanks Alexander for this bug report. > > Here is a patch to fix this issue (and other crash you mentioned in next > mail) > Hi Eric, Thank you for the fix, have not it checked however. I did not know that the second problem (https://lkml.org/lkml/2011/3/23/38) had the same reason. I did not notice inetpeer_free_rcu() in its calltrace. Thanks for that. > > [PATCH] ipv4: fix ip_rt_update_pmtu() > > commit 2c8cec5c10bc (Cache learned PMTU information in inetpeer) added > an extra inet_putpeer() call in ip_rt_update_pmtu(). > > This results in various problems, since we can free one inetpeer, while > it is still in use. > > Ref: http://www.spinics.net/lists/netdev/msg159121.html > > Reported-by: Alexander Beregalov <a.beregalov@gmail.com> > Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> > --- > net/ipv4/route.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/net/ipv4/route.c b/net/ipv4/route.c > index 870b518..34921b0 100644 > --- a/net/ipv4/route.c > +++ b/net/ipv4/route.c > @@ -1593,8 +1593,6 @@ static void ip_rt_update_pmtu(struct dst_entry *dst, u32 mtu) > rt->rt_peer_genid = rt_peer_genid(); > } > check_peer_pmtu(dst, peer); > - > - inet_putpeer(peer); > } > } > > > > -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Eric Dumazet <eric.dumazet@gmail.com> Date: Wed, 23 Mar 2011 10:49:39 +0100 > [PATCH] ipv4: fix ip_rt_update_pmtu() > > commit 2c8cec5c10bc (Cache learned PMTU information in inetpeer) added > an extra inet_putpeer() call in ip_rt_update_pmtu(). > > This results in various problems, since we can free one inetpeer, while > it is still in use. > > Ref: http://www.spinics.net/lists/netdev/msg159121.html > > Reported-by: Alexander Beregalov <a.beregalov@gmail.com> > Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Applied, thanks Eric. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/net/ipv4/route.c b/net/ipv4/route.c index 870b518..34921b0 100644 --- a/net/ipv4/route.c +++ b/net/ipv4/route.c @@ -1593,8 +1593,6 @@ static void ip_rt_update_pmtu(struct dst_entry *dst, u32 mtu) rt->rt_peer_genid = rt_peer_genid(); } check_peer_pmtu(dst, peer); - - inet_putpeer(peer); } }