]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
tcp: fix initial tp->rcvq_space.space value for passive TS enabled flows
authorEric Dumazet <edumazet@google.com>
Tue, 13 May 2025 19:39:14 +0000 (19:39 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2025 10:07:33 +0000 (11:07 +0100)
commit6030752604899e482b3e4c0431fc384beca726f6
tree623882ea67d9b40711c48c6214727dc452f19b2c
parente74f4433ed75e9d0a55c28cfb50d03ca88450e53
tcp: fix initial tp->rcvq_space.space value for passive TS enabled flows

[ Upstream commit cd171461b90a2d2cf230943df60d580174633718 ]

tcp_rcv_state_process() must tweak tp->advmss for TS enabled flows
before the call to tcp_init_transfer() / tcp_init_buffer_space().

Otherwise tp->rcvq_space.space is off by 120 bytes
(TCP_INIT_CWND * TCPOLEN_TSTAMP_ALIGNED).

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Wei Wang <weiwan@google.com>
Link: https://patch.msgid.link/20250513193919.1089692-7-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/ipv4/tcp_input.c