From: David Miller <davem@davemloft.net>
To: gaofeng@cn.fujitsu.com
Cc: steffen.klassert@secunet.com, netdev@vger.kernel.org
Subject: Re: [PATCH 1/4] ipv4: Fix pmtu propagating
Date: Tue, 08 Nov 2011 14:19:50 -0500 (EST) [thread overview]
Message-ID: <20111108.141950.1576262997640523669.davem@davemloft.net> (raw)
In-Reply-To: <20111019.153208.1743995025598236810.davem@davemloft.net>
Steffen I look at this specific patch again.
The peer should be found and loaded up, and the PMTU propagated, when
the route cache entry is created. Specifically rt_init_metrics() will
find any existing peer, and do the whole check_peer_pmtu() sequence
that ipv4_dst_check() does.
If we have some issue with UDP or RAW caching a route past the first
use after the route lookup, yes we have to introduce a dst_check()
call somewhere.
But unilaterally doing this on every CORK setup seems at least very
excessive. Because CORK setup happens even for single sends. One
such example is ip_make_skb().
ip_make_skb() is used by, f.e., udp_sendmsg() when corkreq is false.
And in this case 'rt' is used immediately after being looked up
in udp_sendmsg().
And, as far as I can tell, routines like udp_sendmsg() in fact already
handle the "cached route across multiple sendmsg() calls" case too.
Specifically, udp_sendmsg() does this:
if (connected)
rt = (struct rtable *)sk_dst_check(sk, 0);
otherwise it makes a completely fresh route lookup.
RAW sendmsg unconditionally makes a fresh route lookup on every
sendmsg call. So it should be OK too.
So I really fail to see the problematic case. Therefore, if it exists
you'll have to give me an exact sequence of events that leads to the
problem.
I suspect that your real problem has nothing to do with UDP or RAW,
but rather the issue is that entries already in the routing cache
with a NULL peer need to be refreshed with peer information created
in another context.
next prev parent reply other threads:[~2011-11-08 19:20 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-11 11:08 [PATCH net 0/4] ipv4: various pmtu discovery fixes Steffen Klassert
2011-10-11 11:09 ` [PATCH 1/4] ipv4: Fix pmtu propagating Steffen Klassert
2011-10-12 21:02 ` David Miller
2011-10-13 10:09 ` Steffen Klassert
2011-10-13 17:58 ` David Miller
2011-10-14 5:54 ` Steffen Klassert
2011-10-17 12:18 ` Steffen Klassert
2011-10-19 9:07 ` Gao feng
2011-10-19 19:32 ` David Miller
2011-11-08 19:19 ` David Miller [this message]
2011-11-08 19:33 ` David Miller
2011-11-09 12:08 ` Steffen Klassert
2011-11-21 7:56 ` Steffen Klassert
2011-12-01 18:40 ` David Miller
2011-10-11 11:10 ` [PATCH 2/4] ipv4: Update pmtu informations on inetpeer only for output routes Steffen Klassert
2011-10-12 21:08 ` David Miller
2011-10-14 6:34 ` Steffen Klassert
2011-11-08 19:36 ` David Miller
2011-11-09 12:11 ` Steffen Klassert
2011-11-14 10:12 ` Steffen Klassert
2011-11-14 19:33 ` David Miller
2011-11-15 10:00 ` Steffen Klassert
2011-11-22 13:20 ` Steffen Klassert
2011-10-11 11:11 ` [PATCH 3/4] ipv4: Fix inetpeer expiration handling Steffen Klassert
2011-10-20 6:24 ` Gao feng
2011-11-08 19:38 ` David Miller
2011-11-09 12:47 ` Steffen Klassert
2011-10-11 11:12 ` [PATCH 4/4] ipv4: Fix inetpeer expire time information Steffen Klassert
2011-10-11 19:54 ` [PATCH net 0/4] ipv4: various pmtu discovery fixes David Miller
2011-11-08 19:41 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20111108.141950.1576262997640523669.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=gaofeng@cn.fujitsu.com \
--cc=netdev@vger.kernel.org \
--cc=steffen.klassert@secunet.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).