[PATCH v6 net-next 01/14] tcp: reorganize tcp_in_ack_event() and tcp_count_delivered()

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen - Move tcp_count_delivered() earlier and split tcp_count_delivered_ce() out of it - Move tcp_in_ack_event() later - While at it, remove the inline from tcp_in_ack_event() and let the compiler to decide Accurate ECN's heuristics does not know if there is going to be ACE fi

[PATCH v6 net-next 02/14] tcp: create FLAG_TS_PROGRESS

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Whenever timestamp advances, it declares progress which can be used by the other parts of the stack to decide that the ACK is the most recent one seen so far. AccECN will use this flag when deciding whether to use the ACK to update AccECN state or not. Signed-off-by: Ilpo Jä

[PATCH v6 net-next 00/14] AccECN protocol preparation patch series

2024-12-27 Thread chia-yu . chang
From: Chia-Yu Chang Hello, Specific changes in v6 (27-Dec-2024) - Avoid removing removing the potential CA_ACK_WIN_UPDATE in ack_ev_flags of patch #1 (Eric Dumazet ) - Add reviewed-by tag in patches #2, #3, #4, #5, #6, #7, #8, #12, #14 - Foloiwng 2 new pathces are added after patch #9 (Patch th

[PATCH v6 net-next 08/14] gso: AccECN support

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Handling the CWR flag differs between RFC 3168 ECN and AccECN. With RFC 3168 ECN aware TSO (NETIF_F_TSO_ECN) CWR flag is cleared starting from 2nd segment which is incompatible how AccECN handles the CWR flag. Such super-segments are indicated by SKB_GSO_TCP_ECN. With AccECN,

[PATCH v6 net-next 06/14] tcp: rework {__,}tcp_ecn_check_ce() -> tcp_data_ecn_check()

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Rename tcp_ecn_check_ce to tcp_data_ecn_check as it is called only for data segments, not for ACKs (with AccECN, also ACKs may get ECN bits). The extra "layer" in tcp_ecn_check_ce() function just checks for ECN being enabled, that can be moved into tcp_ecn_field_check rather

[PATCH v6 net-next 04/14] tcp: extend TCP flags to allow AE bit/ACE field

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen With AccECN, there's one additional TCP flag to be used (AE) and ACE field that overloads the definition of AE, CWR, and ECE flags. As tcp_flags was previously only 1 byte, the byte-order stuff needs to be added to it's handling. Signed-off-by: Ilpo Järvinen Signed-off-by: C

[PATCH v6 net-next 07/14] tcp: helpers for ECN mode handling

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Create helpers for TCP ECN modes. No functional changes. Signed-off-by: Ilpo Järvinen Signed-off-by: Chia-Yu Chang Reviewed-by: Eric Dumazet --- include/net/tcp.h| 44 net/ipv4/tcp.c | 2 +- net/ipv4/tcp_dctcp.c

[PATCH v6 net-next 09/14] gro: prevent ACE field corruption & better AccECN handling

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen There are important differences in how the CWR field behaves in RFC3168 and AccECN. With AccECN, CWR flag is part of the ACE counter and its changes are important so adjust the flags changed mask accordingly. Also, if CWR is there, set the Accurate ECN GSO flag to avoid corru

[PATCH v6 net-next 03/14] tcp: use BIT() macro in include/net/tcp.h

2024-12-27 Thread chia-yu . chang
From: Chia-Yu Chang Use BIT() macro for TCP flags field and TCP congestion control flags that will be used by the congestion control algorithm. No functional changes. Signed-off-by: Chia-Yu Chang Reviewed-by: Ilpo Järvinen Reviewed-by: Eric Dumazet --- include/net/tcp.h | 21 +++

[PATCH v6 net-next 05/14] tcp: reorganize SYN ECN code

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Prepare for AccECN that needs to have access here on IP ECN field value which is only available after INET_ECN_xmit(). No functional changes. Signed-off-by: Ilpo Järvinen Signed-off-by: Chia-Yu Chang Reviewed-by: Eric Dumazet --- net/ipv4/tcp_output.c | 5 +++-- 1 file c

[PATCH v6 net-next 12/14] tcp: AccECN support to tcp_add_backlog

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen AE flag needs to be preserved for AccECN. Signed-off-by: Ilpo Järvinen Signed-off-by: Chia-Yu Chang Reviewed-by: Eric Dumazet --- net/ipv4/tcp_ipv4.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index b0b8

[PATCH v6 net-next 11/14] virtio_net: Accurate ECN flag in virtio_net_hdr

2024-12-27 Thread chia-yu . chang
From: Chia-Yu Chang Unlike RFC 3168 ECN, accurate ECN uses the CWR flag as part of the ACE field to count new packets with CE mark; however, it will be corrupted by the RFC 3168 ECN-aware TSO. Therefore, fallback shall be applied by seting NETIF_F_GSO_ACCECN to ensure that the CWR flag should not

[PATCH v6 net-next 14/14] tcp: Pass flags to __tcp_send_ack

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen Accurate ECN needs to send custom flags to handle IP-ECN field reflection during handshake. Signed-off-by: Ilpo Järvinen Signed-off-by: Chia-Yu Chang Reviewed-by: Eric Dumazet --- include/net/tcp.h | 2 +- net/ipv4/bpf_tcp_ca.c | 2 +- net/ipv4/tcp_dctcp.h | 2 +- ne

[PATCH v6 net-next 13/14] tcp: add new TCP_TW_ACK_OOW state and allow ECN bits in TOS

2024-12-27 Thread chia-yu . chang
From: Ilpo Järvinen ECN bits in TOS are always cleared when sending in ACKs in TW. Clearing them is problematic for TCP flows that used Accurate ECN because ECN bits decide which service queue the packet is placed into (L4S vs Classic). Effectively, TW ACKs are always downgraded from L4S to Class

[PATCH v6 net-next 10/14] net: hns3/mlx5e: avoid corrupting CWR flag when receiving GRO packet

2024-12-27 Thread chia-yu . chang
From: Chia-Yu Chang In Accurate ECN, ACE counter (AE, ECE, CWR flags) changes only when new CE packets arrive, while setting SKB_GSO_TCP_ECN in case of not knowing the ECN variant can result in header change that corrupts the ACE field. The new flag SKB_GSO_TCP_ACCECN is to prevent SKB_GSO_TCP_EC

Re: [PATCH v6 net-next 00/14] AccECN protocol preparation patch series

2024-12-27 Thread Jakub Kicinski
On Fri, 27 Dec 2024 20:11:57 +0100 chia-yu.ch...@nokia-bell-labs.com wrote: > Hello Hello. Someone may still review, but: ## Form letter - winter-break Networking development is suspended for winter holidays, until Jan 2nd. We are currently accepting bug fixes only, see the announcements at: h