Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 24 Feb 2024 16:15:39 GMT
From:      Richard Scheffenegger <rscheff@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 40fdc6d25f01 - main - tcp: provide correct snd_fack on post_recovery
Message-ID:  <202402241615.41OGFd22091801@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by rscheff:

URL: https://cgit.FreeBSD.org/src/commit/?id=40fdc6d25f01eea7767f1ba21efcde0e8e26b5eb

commit 40fdc6d25f01eea7767f1ba21efcde0e8e26b5eb
Author:     Richard Scheffenegger <rscheff@FreeBSD.org>
AuthorDate: 2024-02-24 15:53:32 +0000
Commit:     Richard Scheffenegger <rscheff@FreeBSD.org>
CommitDate: 2024-02-24 15:55:31 +0000

    tcp: provide correct snd_fack on post_recovery
    
    Ensure that snd_fack holds a valid value when doing
    the post_recovery CC processing, for preparation of
    the cc_cubic update, so that local pipe calculations
    can correctly refer to snd_fack during and after CC events.
    
    Reviewed By:            tuexen, #transport
    Sponsored by:           NetApp, Inc.
    Differential Revision:  https://reviews.freebsd.org/D43957
---
 sys/netinet/tcp_input.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c
index f023d7477790..8df975bcee54 100644
--- a/sys/netinet/tcp_input.c
+++ b/sys/netinet/tcp_input.c
@@ -479,6 +479,10 @@ cc_post_recovery(struct tcpcb *tp, struct tcphdr *th)
 	INP_WLOCK_ASSERT(tptoinpcb(tp));
 
 	if (CC_ALGO(tp)->post_recovery != NULL) {
+		if (SEQ_LT(tp->snd_fack, th->th_ack) ||
+		    SEQ_GT(tp->snd_fack, tp->snd_max)) {
+			tp->snd_fack = th->th_ack;
+		}
 		tp->t_ccv.curack = th->th_ack;
 		CC_ALGO(tp)->post_recovery(&tp->t_ccv);
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202402241615.41OGFd22091801>