Commit 6d67e9be authored by Feng King's avatar Feng King Committed by David S. Miller

tcp: Fix comments for Nagle algorithm

TCP_NODELAY is weaker than TCP_CORK, when TCP_CORK was set, small
segments will always pass Nagle test regardless of TCP_NODELAY option.
Signed-off-by: default avatarFeng King <kinwin2008@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 59caa561
...@@ -1382,7 +1382,7 @@ static inline int tcp_minshall_check(const struct tcp_sock *tp) ...@@ -1382,7 +1382,7 @@ static inline int tcp_minshall_check(const struct tcp_sock *tp)
/* Return 0, if packet can be sent now without violation Nagle's rules: /* Return 0, if packet can be sent now without violation Nagle's rules:
* 1. It is full sized. * 1. It is full sized.
* 2. Or it contains FIN. (already checked by caller) * 2. Or it contains FIN. (already checked by caller)
* 3. Or TCP_NODELAY was set. * 3. Or TCP_CORK is not set, and TCP_NODELAY is set.
* 4. Or TCP_CORK is not set, and all sent packets are ACKed. * 4. Or TCP_CORK is not set, and all sent packets are ACKed.
* With Minshall's modification: all sent small packets are ACKed. * With Minshall's modification: all sent small packets are ACKed.
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment