summaryrefslogtreecommitdiffstats
path: root/sys/netinet/tcp_output.c
diff options
context:
space:
mode:
authorjlemon <jlemon@FreeBSD.org>2003-02-19 21:18:23 +0000
committerjlemon <jlemon@FreeBSD.org>2003-02-19 21:18:23 +0000
commit8b16df5c375c62f55a0bcea508d27d701a505e02 (patch)
tree5fd0290a91d0e3b84e43be4acc5477d4dc970210 /sys/netinet/tcp_output.c
parent13bf23a61cb3844604c8df4e11030488a4557188 (diff)
downloadFreeBSD-src-8b16df5c375c62f55a0bcea508d27d701a505e02.zip
FreeBSD-src-8b16df5c375c62f55a0bcea508d27d701a505e02.tar.gz
Clean up delayed acks and T/TCP interactions:
- delay acks for T/TCP regardless of delack setting - fix bug where a single pass through tcp_input might not delay acks - use callout_active() instead of callout_pending() Sponsored by: DARPA, NAI Labs
Diffstat (limited to 'sys/netinet/tcp_output.c')
-rw-r--r--sys/netinet/tcp_output.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/netinet/tcp_output.c b/sys/netinet/tcp_output.c
index 34b0d84..a917ed3 100644
--- a/sys/netinet/tcp_output.c
+++ b/sys/netinet/tcp_output.c
@@ -339,8 +339,9 @@ again:
* next expected input). If the difference is at least two
* max size segments, or at least 50% of the maximum possible
* window, then want to send a window update to peer.
+ * Skip this if the connection is in T/TCP half-open state.
*/
- if (win > 0) {
+ if (win > 0 && !(tp->t_flags & TF_NEEDSYN)) {
/*
* "adv" is the amount we can increase the window,
* taking into account that we are limited by
@@ -965,8 +966,8 @@ out:
if (win > 0 && SEQ_GT(tp->rcv_nxt+win, tp->rcv_adv))
tp->rcv_adv = tp->rcv_nxt + win;
tp->last_ack_sent = tp->rcv_nxt;
- tp->t_flags &= ~TF_ACKNOW;
- if (tcp_delack_enabled)
+ tp->t_flags &= ~(TF_ACKNOW | TF_DELACK);
+ if (callout_active(tp->tt_delack))
callout_stop(tp->tt_delack);
#if 0
/*
OpenPOWER on IntegriCloud