diff options
author | fenner <fenner@FreeBSD.org> | 1999-01-20 17:32:01 +0000 |
---|---|---|
committer | fenner <fenner@FreeBSD.org> | 1999-01-20 17:32:01 +0000 |
commit | 505f7489c786c6d9187a23cdcaff81d58054cfa2 (patch) | |
tree | b11687e0b4226a6a70dd505540489c7122139567 /sys/netinet/tcp_usrreq.c | |
parent | 801f1c1fa1926446d11f8e3767651f802a16222b (diff) | |
download | FreeBSD-src-505f7489c786c6d9187a23cdcaff81d58054cfa2.zip FreeBSD-src-505f7489c786c6d9187a23cdcaff81d58054cfa2.tar.gz |
Add a flag, passed to pru_send routines, PRUS_MORETOCOME. This
flag means that there is more data to be put into the socket buffer.
Use it in TCP to reduce the interaction between mbuf sizes and the
Nagle algorithm.
Based on: "Justin C. Walker" <justin@apple.com>'s description of Apple's
fix for this problem.
Diffstat (limited to 'sys/netinet/tcp_usrreq.c')
-rw-r--r-- | sys/netinet/tcp_usrreq.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/netinet/tcp_usrreq.c b/sys/netinet/tcp_usrreq.c index 9c00208..66519ce 100644 --- a/sys/netinet/tcp_usrreq.c +++ b/sys/netinet/tcp_usrreq.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * From: @(#)tcp_usrreq.c 8.2 (Berkeley) 1/3/94 - * $Id: tcp_usrreq.c,v 1.38 1998/08/23 03:07:15 wollman Exp $ + * $Id: tcp_usrreq.c,v 1.39 1998/12/07 21:58:42 archie Exp $ */ #include "opt_tcpdebug.h" @@ -368,8 +368,13 @@ tcp_usr_send(struct socket *so, int flags, struct mbuf *m, socantsendmore(so); tp = tcp_usrclosed(tp); } - if (tp != NULL) + if (tp != NULL) { + if (flags & PRUS_MORETOCOME) + tp->t_flags |= TF_MORETOCOME; error = tcp_output(tp); + if (flags & PRUS_MORETOCOME) + tp->t_flags &= ~TF_MORETOCOME; + } } else { if (sbspace(&so->so_snd) < -512) { m_freem(m); |