diff options
author | Nayana Bidari <nybidari@google.com> | 2020-12-16 12:17:02 -0800 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-12-16 12:19:21 -0800 |
commit | 0c92b3782ae641b59d512a922f766721a34d7e9e (patch) | |
tree | f1d9b73b267b54a9dc14693d6a2956e1b72a3ba7 /pkg/tcpip/stack | |
parent | 7da25e6dc3095378ecaf292759ef84b656a306b8 (diff) |
Add support to count the number of packets SACKed.
sacked_out is required in RACK to check the number of duplicate
acknowledgements during updating the reorder window. If there is no reordering
and the value for sacked_out is greater than the classic threshold value 3,
then reorder window is set to zero.
It is calculated by counting the number of segments sacked in the ACK and is
reduced when a cumulative ACK is received which covers the SACK blocks. This
value is set to zero when the connection enters recovery.
PiperOrigin-RevId: 347872246
Diffstat (limited to 'pkg/tcpip/stack')
-rw-r--r-- | pkg/tcpip/stack/stack.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkg/tcpip/stack/stack.go b/pkg/tcpip/stack/stack.go index dc4f5b3e7..026d330c4 100644 --- a/pkg/tcpip/stack/stack.go +++ b/pkg/tcpip/stack/stack.go @@ -171,6 +171,9 @@ type TCPSenderState struct { // Outstanding is the number of packets in flight. Outstanding int + // SackedOut is the number of packets which have been selectively acked. + SackedOut int + // SndWnd is the send window size in bytes. SndWnd seqnum.Size |