From: Felix Fietkau <nbd@nbd.name>
To: Eric Dumazet <edumazet@google.com>
Cc: netdev@vger.kernel.org, Neal Cardwell <ncardwell@google.com>,
Kuniyuki Iwashima <kuniyu@amazon.com>,
"David S. Miller" <davem@davemloft.net>,
David Ahern <dsahern@kernel.org>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
Willem de Bruijn <willemb@google.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net v2] net: ipv6: fix TCP GSO segmentation with NAT
Date: Mon, 10 Mar 2025 15:21:39 +0100 [thread overview]
Message-ID: <23698682-9e31-42a9-8346-fab7738f79c5@nbd.name> (raw)
In-Reply-To: <CANn89i+tX02HsfcGx1g5fdg9N4Cx=FNDk886KNPqsiem7rPcJA@mail.gmail.com>
On 10.03.25 14:50, Eric Dumazet wrote:
> On Mon, Mar 10, 2025 at 12:21 PM Felix Fietkau <nbd@nbd.name> wrote:
>>
>> When updating the source/destination address, the TCP/UDP checksum needs to
>> be updated as well.
>>
>> Fixes: bee88cd5bd83 ("net: add support for segmenting TCP fraglist GSO packets")
>> Signed-off-by: Felix Fietkau <nbd@nbd.name>
>> ---
>> v2: move code to make it similar to __tcpv4_gso_segment_list_csum
>>
>> net/ipv6/tcpv6_offload.c | 18 ++++++++++++++----
>> 1 file changed, 14 insertions(+), 4 deletions(-)
>>
>> diff --git a/net/ipv6/tcpv6_offload.c b/net/ipv6/tcpv6_offload.c
>> index a45bf17cb2a1..34dd0cee3ba6 100644
>> --- a/net/ipv6/tcpv6_offload.c
>> +++ b/net/ipv6/tcpv6_offload.c
>> @@ -94,10 +94,20 @@ INDIRECT_CALLABLE_SCOPE int tcp6_gro_complete(struct sk_buff *skb, int thoff)
>> }
>>
>> static void __tcpv6_gso_segment_csum(struct sk_buff *seg,
>> + struct in6_addr *oldip,
>> + const struct in6_addr *newip,
>> __be16 *oldport, __be16 newport)
>> {
>> struct tcphdr *th;
>>
>> + if (!ipv6_addr_equal(oldip, newip)) {
>> + inet_proto_csum_replace16(&th->check, seg,
>
> th is not initialized yet.
Sorry, I had this fixed locally, but forgot to add it before sending.
Will send v3 later.
- Felix
next prev parent reply other threads:[~2025-03-10 14:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-10 11:21 Felix Fietkau
2025-03-10 13:50 ` Eric Dumazet
2025-03-10 14:21 ` Felix Fietkau [this message]
2025-03-11 19:01 ` kernel test robot
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=23698682-9e31-42a9-8346-fab7738f79c5@nbd.name \
--to=nbd@nbd.name \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=kuniyu@amazon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=willemb@google.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
all inboxes | Powered by JetHome®