lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89i+Nn7ce8=r07b00Acq9acmX9Lm6rTOx6L59REqaV2v68g@mail.gmail.com>
Date:   Tue, 25 Jan 2022 09:20:11 -0800
From:   Eric Dumazet <edumazet@...gle.com>
To:     David Ahern <dsahern@...il.com>
Cc:     netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH net-next] net: Adjust sk_gso_max_size once when set

On Tue, Jan 25, 2022 at 9:16 AM David Ahern <dsahern@...il.com> wrote:
>
> On 1/25/22 9:46 AM, Eric Dumazet wrote:
> > On Mon, Jan 24, 2022 at 6:45 PM David Ahern <dsahern@...nel.org> wrote:
> >>
> >> sk_gso_max_size is set based on the dst dev. Both users of it
> >> adjust the value by the same offset - (MAX_TCP_HEADER + 1). Rather
> >> than compute the same adjusted value on each call do the adjustment
> >> once when set.
> >>
> >> Signed-off-by: David Ahern <dsahern@...nel.org>
> >> Cc: Eric Dumazet <edumazet@...gle.com>
> >
> >
> > SGTM, thanks.
> >
> > Reviewed-by: Eric Dumazet <edumazet@...gle.com>
>
> The git history does not explain why MAX_TCP_HEADER is used to lower
> sk_gso_max_size. Do you recall the history on it?

Simply that max IP datagram size is 64K

And TCP is sizing its payload size there (eg in  tcp_tso_autosize()),
when skb only contains payload.

Headers are added later in various xmit layers.

MAX_TCP_HEADER is chosen to avoid re-allocs of skb->head in typical workload.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ