OSDN Git Service

tcp: tracking packets with CE marks in BW rate sample
authorYuchung Cheng <ycheng@google.com>
Thu, 23 Sep 2021 21:17:07 +0000 (21:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 24 Sep 2021 13:16:40 +0000 (14:16 +0100)
commit40bc6063796ec77b6073861f9a1993be20d5befd
treecc2672d4809c34d3f8318724bb557a9fb641ddca
parentae98f40d32cd0ee6fc222e765734ffa497a0a95e
tcp: tracking packets with CE marks in BW rate sample

In order to track CE marks per rate sample (one round trip), TCP needs a
per-skb header field to record the tp->delivered_ce count when the skb
was sent. To make space, we replace the "last_in_flight" field which is
used exclusively for NV congestion control. The stat needed by NV can be
alternatively approximated by existing stats tcp_sock delivered and
mss_cache.

This patch counts the number of packets delivered which have CE marks in
the rate sample, using similar approach of delivery accounting.

Cc: Lawrence Brakmo <brakmo@fb.com>
Signed-off-by: Yuchung Cheng <ycheng@google.com>
Acked-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Luke Hsiao <lukehsiao@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/tcp.h
net/ipv4/tcp_input.c
net/ipv4/tcp_output.c
net/ipv4/tcp_rate.c