[PATCH net-next v3 0/6] tcp: RFC 7323-compliant window retraction handling

Simon Baatz via B4 Relay posted 6 patches 1 week, 5 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/multipath-tcp/mptcp_net-next tags/patchew/20260309-tcp._5Frfc7323._5Fretract._5Fwnd._5Frfc-v3-0-4c7f96b1ec69@gmail.com
.../networking/net_cachelines/tcp_sock.rst         |   1 +
include/linux/tcp.h                                |   3 +
include/net/tcp.h                                  |  22 ++++
net/ipv4/tcp.c                                     |   2 +
net/ipv4/tcp_fastopen.c                            |   1 +
net/ipv4/tcp_input.c                               |  11 +-
net/ipv4/tcp_minisocks.c                           |   1 +
net/ipv4/tcp_output.c                              |   3 +
net/mptcp/options.c                                |   6 +-
.../net/packetdrill/tcp_rcv_big_endseq.pkt         |   2 +-
.../net/packetdrill/tcp_rcv_neg_window.pkt         |  26 ++++
.../net/packetdrill/tcp_rcv_wnd_shrink_allowed.pkt |  40 +++++++
.../net/packetdrill/tcp_rcv_wnd_shrink_nomem.pkt   | 132 +++++++++++++++++++++
13 files changed, 242 insertions(+), 8 deletions(-)
[PATCH net-next v3 0/6] tcp: RFC 7323-compliant window retraction handling
Posted by Simon Baatz via B4 Relay 1 week, 5 days ago
Hi,

this series implements the receiver-side requirements for TCP window
retraction as specified in RFC 7323 and adds packetdrill tests to
cover the new behavior.

Please see the first patch for background and implementation
details. Since MPTCP adjusts the TCP receive window on subflows, the
relevant MPTCP code paths are updated accordingly.

Signed-off-by: Simon Baatz <gmbnomis@gmail.com>
---
Changes in v3:

- Address MPTCP subflow-level rcv_wnd adjustments
- Removed RFC status
- Adapt tcp_rcv_wnd_shrink_nomem.pkt to reflect 026dfef287c0 ("tcp:
  give up on stronger sk_rcvbuf checks (for now)")
- Link to v2: https://lore.kernel.org/r/20260226-tcp_rfc7323_retract_wnd_rfc-v2-0-aa3f8f9cc639@gmail.com

Changes in v2:

- tcp_rcv_wnd_shrink_nomem.pkt tests more RX code paths using various
  segment types. It also uses a more drastic rcv. buffer reduction (1MB
  to 16KB).
- Setting the TCP_REPAIR_WINDOW socket option initializes rcv_mwnd_seq.
- SKB_DROP_REASON_TCP_OVERWINDOW increases LINUX_MIB_BEYOND_WINDOW now.
- Moved rcv_mwnd_seq into rcv_wnd's cacheline group.
- Small editorial changes
- Link to v1: https://lore.kernel.org/r/20260220-tcp_rfc7323_retract_wnd_rfc-v1-0-904942561479@gmail.com

---
Simon Baatz (6):
      tcp: implement RFC 7323 window retraction receiver requirements
      mptcp: keep rcv_mwnd_seq in sync with subflow rcv_wnd
      tcp: increase LINUX_MIB_BEYOND_WINDOW for SKB_DROP_REASON_TCP_OVERWINDOW
      selftests/net: packetdrill: add tcp_rcv_wnd_shrink_nomem.pkt
      selftests/net: packetdrill: add tcp_rcv_wnd_shrink_allowed.pkt
      selftests/net: packetdrill: add tcp_rcv_neg_window.pkt

 .../networking/net_cachelines/tcp_sock.rst         |   1 +
 include/linux/tcp.h                                |   3 +
 include/net/tcp.h                                  |  22 ++++
 net/ipv4/tcp.c                                     |   2 +
 net/ipv4/tcp_fastopen.c                            |   1 +
 net/ipv4/tcp_input.c                               |  11 +-
 net/ipv4/tcp_minisocks.c                           |   1 +
 net/ipv4/tcp_output.c                              |   3 +
 net/mptcp/options.c                                |   6 +-
 .../net/packetdrill/tcp_rcv_big_endseq.pkt         |   2 +-
 .../net/packetdrill/tcp_rcv_neg_window.pkt         |  26 ++++
 .../net/packetdrill/tcp_rcv_wnd_shrink_allowed.pkt |  40 +++++++
 .../net/packetdrill/tcp_rcv_wnd_shrink_nomem.pkt   | 132 +++++++++++++++++++++
 13 files changed, 242 insertions(+), 8 deletions(-)
---
base-commit: 0bcac7b11262557c990da1ac564d45777eb6b005
change-id: 20260220-tcp_rfc7323_retract_wnd_rfc-c8a2d2baebde

Best regards,
-- 
Simon Baatz <gmbnomis@gmail.com>
Re: [PATCH net-next v3 0/6] tcp: RFC 7323-compliant window retraction handling
Posted by MPTCP CI 1 week, 5 days ago
Hi Simon,

Thank you for your modifications, that's great!

Our CI did some validations and here is its report:

- KVM Validation: normal (except selftest_mptcp_join): Notice: Boot failures, rebooted and continued 🔴
- KVM Validation: normal (only selftest_mptcp_join): Success! ✅
- KVM Validation: debug (except selftest_mptcp_join): Success! ✅
- KVM Validation: debug (only selftest_mptcp_join): Success! ✅
- KVM Validation: btf-normal (only bpftest_all): Success! ✅
- KVM Validation: btf-debug (only bpftest_all): Success! ✅
- Task: https://github.com/multipath-tcp/mptcp_net-next/actions/runs/22844479802

Initiator: Patchew Applier
Commits: https://github.com/multipath-tcp/mptcp_net-next/commits/82f2ad5662fb
Patchwork: https://patchwork.kernel.org/project/mptcp/list/?series=1063485


If there are some issues, you can reproduce them using the same environment as
the one used by the CI thanks to a docker image, e.g.:

    $ cd [kernel source code]
    $ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm -it \
        --pull always mptcp/mptcp-upstream-virtme-docker:latest \
        auto-normal

For more details:

    https://github.com/multipath-tcp/mptcp-upstream-virtme-docker


Please note that despite all the efforts that have been already done to have a
stable tests suite when executed on a public CI like here, it is possible some
reported issues are not due to your modifications. Still, do not hesitate to
help us improve that ;-)

Cheers,
MPTCP GH Action bot
Bot operated by Matthieu Baerts (NGI0 Core)
Re: [PATCH net-next v3 0/6] tcp: RFC 7323-compliant window retraction handling
Posted by patchwork-bot+netdevbpf@kernel.org 1 week ago
Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 09 Mar 2026 09:02:25 +0100 you wrote:
> Hi,
> 
> this series implements the receiver-side requirements for TCP window
> retraction as specified in RFC 7323 and adds packetdrill tests to
> cover the new behavior.
> 
> Please see the first patch for background and implementation
> details. Since MPTCP adjusts the TCP receive window on subflows, the
> relevant MPTCP code paths are updated accordingly.
> 
> [...]

Here is the summary with links:
  - [net-next,v3,1/6] tcp: implement RFC 7323 window retraction receiver requirements
    https://git.kernel.org/netdev/net-next/c/0e24d17bd966
  - [net-next,v3,2/6] mptcp: keep rcv_mwnd_seq in sync with subflow rcv_wnd
    https://git.kernel.org/netdev/net-next/c/81714374a29c
  - [net-next,v3,3/6] tcp: increase LINUX_MIB_BEYOND_WINDOW for SKB_DROP_REASON_TCP_OVERWINDOW
    https://git.kernel.org/netdev/net-next/c/e2b9c52a2b00
  - [net-next,v3,4/6] selftests/net: packetdrill: add tcp_rcv_wnd_shrink_nomem.pkt
    https://git.kernel.org/netdev/net-next/c/ec1adf8ecf95
  - [net-next,v3,5/6] selftests/net: packetdrill: add tcp_rcv_wnd_shrink_allowed.pkt
    https://git.kernel.org/netdev/net-next/c/ba58b3e70b86
  - [net-next,v3,6/6] selftests/net: packetdrill: add tcp_rcv_neg_window.pkt
    https://git.kernel.org/netdev/net-next/c/3eb371eddad0

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html