History

tcp: add documentation for tcp_ca_state

Add documentation to the tcp_ca_state enum, since this enum is exposed in uapi.

Soheil Hassas Yeganeh committed 7 years ago

Commit 576fd2f1 parent e6d14071 file · +27 −0Browse files

Showing the changes to include/uapi/linux (1 of 1 file). Show all

Unified · Split

include/uapi/linux/tcp.h+27−0
@@ -160,15 +160,42 @@ enum { · 159 unmodified lines
160160 #define TCPI_OPT_ECN_SEEN 16 /* we received at least one packet with ECT */
161161 #define TCPI_OPT_SYN_DATA 32 /* SYN-ACK acked data in SYN sent or rcvd */
162162
163+/*
164+ * Sender's congestion state indicating normal or abnormal situations
165+ * in the last round of packets sent. The state is driven by the ACK
166+ * information and timer events.
167+ */
163168 enum tcp_ca_state {
169+ /*
170+ * Nothing bad has been observed recently.
171+ * No apparent reordering, packet loss, or ECN marks.
172+ */
164173 TCP_CA_Open = 0,
165174 #define TCPF_CA_Open (1<<TCP_CA_Open)
175+ /*
176+ * The sender enters disordered state when it has received DUPACKs or
177+ * SACKs in the last round of packets sent. This could be due to packet
178+ * loss or reordering but needs further information to confirm packets
179+ * have been lost.
180+ */
166181 TCP_CA_Disorder = 1,
167182 #define TCPF_CA_Disorder (1<<TCP_CA_Disorder)
183+ /*
184+ * The sender enters Congestion Window Reduction (CWR) state when it
185+ * has received ACKs with ECN-ECE marks, or has experienced congestion
186+ * or packet discard on the sender host (e.g. qdisc).
187+ */
168188 TCP_CA_CWR = 2,
169189 #define TCPF_CA_CWR (1<<TCP_CA_CWR)
190+ /*
191+ * The sender is in fast recovery and retransmitting lost packets,
192+ * typically triggered by ACK events.
193+ */
170194 TCP_CA_Recovery = 3,
171195 #define TCPF_CA_Recovery (1<<TCP_CA_Recovery)
196+ /*
197+ * The sender is in loss recovery triggered by retransmission timeout.
198+ */
172199 TCP_CA_Loss = 4
173200 #define TCPF_CA_Loss (1<<TCP_CA_Loss)
174201 };