public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Alice Mikityanska <alice.kernel@fastmail.im>
To: Mariusz Klimek <maklimek97@gmail.com>
Cc: netdev@vger.kernel.org, Paolo Abeni <pabeni@redhat.com>,
	Alice Mikityanska <alice@isovalent.com>,
	Alice Mikityanska <alice.kernel@fastmail.im>
Subject: Re: [PATCH net-next v2 0/3] net: gso: fix MTU validation of BIG TCP
Date: Tue, 13 Jan 2026 23:42:31 +0200	[thread overview]
Message-ID: <20260113214232.129356-1-alice.kernel@fastmail.im> (raw)
In-Reply-To: <20260106095243.15105-1-maklimek97@gmail.com>

On Tue, 06 Jan 2026 at 10:52:40 +0100, Mariusz Klimek wrote:
> This series fixes the MTU validation of BIG TCP jumbograms and removes the
> existing IP6SKB_FAKEJUMBO work-around that only fixes the issue in one
> location.

My series removes IPv6 HBH in BIG TCP entirely:

https://lore.kernel.org/netdev/20260113212655.116122-1-alice.kernel@fastmail.im/T/

I believe, it makes this fix no longer necessary.

> For GSO packets, the length that matters for MTU validation is the segment
> length, not the total length of the packet. skb_gso_network_seglen is used
> by skb_gso_validate_network_len to calculate the segment length including
> the network and transport headers and to then verify that the segment
> length is below the MTU.
> 
> skb_gso_network_seglen assumes that the headers of the segments are
> identical to those of the unsegmented packet, but that assumption is
> incorrect for BIG TCP jumbograms which have an added HBH header that is
> removed upon segmentation. The calculated segment length ends up being 8
> bytes more than the actual segment length.
> 
> The actual segment length is set according to the MSS, so the segment
> length calculated by skb_gso_network_seglen is greater than the MTU,
> causing the skb_gso_validate_network_len check to fail despite the fact
> that the actual segment length is lower than the MTU.
> 
> There is currently a work-around that fixes this bug in some cases:
> ip6_xmit sets the IP6SKB_FAKEJUMBO flag for BIG TCP jumbograms, which
> causes the MTU validation in ip6_finish_output_gso to be skipped
> (intentionally). However, this work-around doesn't apply to MTU validations
> performed in other places such as in ip6_forward. BIG TCP jumbograms don't
> pass the MTU validation when forwarded locally and are therefore dropped,
> unless the MTU of the originating interface is lower than the MTUs of the
> rest of the interfaces the packets are forwarded through.
> 
> v2:
>   fix jumbogram check in skb_gso_network_seglen
>   add jumbogram check to skb_gso_mac_seglen as well
> 
> v1:
>   Link: https://lore.kernel.org/netdev/20251127091325.7248-1-maklimek97@gmail.com/
> 
> Mariusz Klimek (3):
>   net: gso: do not include jumbogram HBH header in seglen calculation
>   ipv6: remove IP6SKB_FAKEJUMBO flag
>   selftests/net: remove unnecessary MTU config in big_tcp.sh
> 
>  include/linux/ipv6.h                   |  1 -
>  net/core/gso.c                         | 14 +++++++++-----
>  net/ipv6/ip6_output.c                  |  4 +---
>  tools/testing/selftests/net/big_tcp.sh |  1 -
>  4 files changed, 10 insertions(+), 10 deletions(-)
> 
> -- 
> 2.47.3
> 
> 

  parent reply	other threads:[~2026-01-13 21:42 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-06  9:52 [PATCH net-next v2 0/3] net: gso: fix MTU validation of BIG TCP Mariusz Klimek
2026-01-06  9:52 ` [PATCH net-next v2 1/3] net: gso: do not include jumbogram HBH header in seglen calculation Mariusz Klimek
2026-01-13  8:40   ` Paolo Abeni
2026-01-13 13:51     ` Paolo Abeni
2026-01-14  3:47       ` Jason Wang
2026-01-13 14:14   ` Paolo Abeni
2026-01-14 15:52     ` Mariusz Klimek
2026-01-06  9:52 ` [PATCH net-next v2 2/3] ipv6: remove IP6SKB_FAKEJUMBO flag Mariusz Klimek
2026-01-06  9:52 ` [PATCH net-next v2 3/3] selftests/net: remove unnecessary MTU config in big_tcp.sh Mariusz Klimek
2026-01-13 21:42 ` Alice Mikityanska [this message]
2026-01-30  8:57   ` [PATCH net-next v2 0/3] net: gso: fix MTU validation of BIG TCP Mariusz Klimek
2026-01-30 18:02     ` Alice Mikityanska

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=20260113214232.129356-1-alice.kernel@fastmail.im \
    --to=alice.kernel@fastmail.im \
    --cc=alice@isovalent.com \
    --cc=maklimek97@gmail.com \
    --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