Page MenuHomeFreeBSD

D28114.id82265.diff
No OneTemporary

D28114.id82265.diff

Index: sys/netinet/tcp_input.c
===================================================================
--- sys/netinet/tcp_input.c
+++ sys/netinet/tcp_input.c
@@ -510,6 +510,7 @@
}
/* XXXLAS: EXIT_RECOVERY ? */
tp->t_bytes_acked = 0;
+ tp->sackhint.recover_fs = 0;
}
/*
@@ -2589,6 +2590,9 @@
tp->sackhint.sack_bytes_rexmit;
tp->sackhint.prr_delivered += del_data;
if (pipe > tp->snd_ssthresh) {
+ if (tp->sackhint.recover_fs == 0)
+ tp->sackhint.recover_fs =
+ max(1, tp->snd_nxt - tp->snd_una);
snd_cnt = (tp->sackhint.prr_delivered *
tp->snd_ssthresh /
tp->sackhint.recover_fs) +
@@ -2676,14 +2680,14 @@
tcp_timer_activate(tp, TT_REXMT, 0);
tp->t_rtttime = 0;
if (V_tcp_do_prr) {
- /*
- * snd_ssthresh is already updated by
- * cc_cong_signal.
- */
- tp->sackhint.prr_delivered = 0;
- tp->sackhint.sack_bytes_rexmit = 0;
- if (!(tp->sackhint.recover_fs = tp->snd_nxt - tp->snd_una))
- tp->sackhint.recover_fs = 1;
+ /*
+ * snd_ssthresh is already updated by
+ * cc_cong_signal.
+ */
+ tp->sackhint.prr_delivered = 0;
+ tp->sackhint.sack_bytes_rexmit = 0;
+ tp->sackhint.recover_fs = max(1,
+ tp->snd_nxt - tp->snd_una);
}
if (tp->t_flags & TF_SACK_PERMIT) {
TCPSTAT_INC(
Index: sys/netinet/tcp_subr.c
===================================================================
--- sys/netinet/tcp_subr.c
+++ sys/netinet/tcp_subr.c
@@ -737,6 +737,16 @@
TCPS_HAVEESTABLISHED(tp->t_state) ? TP_KEEPIDLE(tp) :
TP_KEEPINIT(tp));
+ /*
+ * Make sure critical variables are initialized
+ * if transitioning while in Recovery.
+ */
+ if IN_FASTRECOVERY(tp->t_flags) {
+ if (tp->sackhint.recover_fs == 0)
+ tp->sackhint.recover_fs = max(1,
+ tp->snd_nxt - tp->snd_una);
+ }
+
return (0);
}

File Metadata

Mime Type
text/plain
Expires
Fri, Jul 24, 10:52 PM (44 m, 43 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35455285
Default Alt Text
D28114.id82265.diff (1 KB)

Event Timeline