From: Simon Horman <simon.horman@corigine.com>
To: Jiri Benc <jbenc@redhat.com>
Cc: netdev@vger.kernel.org,
Jesse Brandeburg <jesse.brandeburg@intel.com>,
Tony Nguyen <anthony.l.nguyen@intel.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Eyal Birger <eyal.birger@gmail.com>
Subject: Re: [PATCH net v2] vxlan: calculate correct header length for GPE
Date: Fri, 21 Jul 2023 13:46:56 +0100 [thread overview]
Message-ID: <ZLp+QOjOrwTgmOCe@corigine.com> (raw)
In-Reply-To: <544e8c6d0f48af2be49809877c05c0445c0b0c0b.1689843872.git.jbenc@redhat.com>
On Thu, Jul 20, 2023 at 11:05:56AM +0200, Jiri Benc wrote:
> VXLAN-GPE does not add an extra inner Ethernet header. Take that into
> account when calculating header length.
>
> This causes problems in skb_tunnel_check_pmtu, where incorrect PMTU is
> cached.
>
> In the collect_md mode (which is the only mode that VXLAN-GPE
> supports), there's no magic auto-setting of the tunnel interface MTU.
> It can't be, since the destination and thus the underlying interface
> may be different for each packet.
>
> So, the administrator is responsible for setting the correct tunnel
> interface MTU. Apparently, the administrators are capable enough to
> calculate that the maximum MTU for VXLAN-GPE is (their_lower_MTU - 36).
> They set the tunnel interface MTU to 1464. If you run a TCP stream over
> such interface, it's then segmented according to the MTU 1464, i.e.
> producing 1514 bytes frames. Which is okay, this still fits the lower
> MTU.
>
> However, skb_tunnel_check_pmtu (called from vxlan_xmit_one) uses 50 as
> the header size and thus incorrectly calculates the frame size to be
> 1528. This leads to ICMP too big message being generated (locally),
> PMTU of 1450 to be cached and the TCP stream to be resegmented.
>
> The fix is to use the correct actual header size, especially for
> skb_tunnel_check_pmtu calculation.
>
> Fixes: e1e5314de08ba ("vxlan: implement GPE")
> Signed-off-by: Jiri Benc <jbenc@redhat.com>
> ---
> v2: more verbose patch description
Reviewed-by: Simon Horman <simon.horman@corigine.com>
next prev parent reply other threads:[~2023-07-21 12:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-20 9:05 [PATCH net v2] vxlan: calculate correct header length for GPE Jiri Benc
2023-07-21 12:46 ` Simon Horman [this message]
2023-07-24 8:40 ` patchwork-bot+netdevbpf
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=ZLp+QOjOrwTgmOCe@corigine.com \
--to=simon.horman@corigine.com \
--cc=anthony.l.nguyen@intel.com \
--cc=eyal.birger@gmail.com \
--cc=jbenc@redhat.com \
--cc=jesse.brandeburg@intel.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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).