Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Jul 2024 17:13:57 GMT
From:      Cheng Cui <cc@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 9565854ab408 - main - cc_cubic: remove the redundant variable num_cong_events from struct cubic.
Message-ID:  <202407251713.46PHDvBj004200@gitrepo.freebsd.org>

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

URL: https://cgit.FreeBSD.org/src/commit/?id=9565854ab408a6235def12074f98b9ccc0f3008e

commit 9565854ab408a6235def12074f98b9ccc0f3008e
Author:     Cheng Cui <cc@FreeBSD.org>
AuthorDate: 2024-07-19 16:11:59 +0000
Commit:     Cheng Cui <cc@FreeBSD.org>
CommitDate: 2024-07-25 17:11:32 +0000

    cc_cubic: remove the redundant variable num_cong_events from struct cubic.
    
    Summary:
    This variable was added by commit eb5bfdd06565, but unnecessarily needed.
    No functional change.
    
    Reviewed by: tuexen
    
    Differential Revision: https://reviews.freebsd.org/D46042
---
 sys/netinet/cc/cc_cubic.c | 2 --
 sys/netinet/cc/cc_cubic.h | 2 --
 2 files changed, 4 deletions(-)

diff --git a/sys/netinet/cc/cc_cubic.c b/sys/netinet/cc/cc_cubic.c
index b4050326ae31..5141de86ef85 100644
--- a/sys/netinet/cc/cc_cubic.c
+++ b/sys/netinet/cc/cc_cubic.c
@@ -490,13 +490,11 @@ cubic_cong_signal(struct cc_var *ccv, ccsignal_t type)
 		}
 		cubic_data->flags |= CUBICFLAG_CONG_EVENT | CUBICFLAG_RTO_EVENT;
 		cubic_data->undo_W_max = cubic_data->W_max;
-		cubic_data->num_cong_events++;
 		CCV(ccv, snd_cwnd) = mss;
 		break;
 
 	case CC_RTO_ERR:
 		cubic_data->flags &= ~(CUBICFLAG_CONG_EVENT | CUBICFLAG_RTO_EVENT);
-		cubic_data->num_cong_events--;
 		cubic_data->K = cubic_data->undo_K;
 		cubic_data->cwnd_prior = cubic_data->undo_cwnd_prior;
 		cubic_data->W_max = cubic_data->undo_W_max;
diff --git a/sys/netinet/cc/cc_cubic.h b/sys/netinet/cc/cc_cubic.h
index ce6c2a6633d7..592703906d1a 100644
--- a/sys/netinet/cc/cc_cubic.h
+++ b/sys/netinet/cc/cc_cubic.h
@@ -121,8 +121,6 @@ struct cubic {
 	uint64_t	undo_W_max;
 	uint64_t	undo_W_est;
 	uint64_t	undo_cwnd_epoch;
-	/* Number of congestion events experienced */
-	uint64_t	num_cong_events;
 	uint32_t css_baseline_minrtt;
 	uint32_t css_current_round_minrtt;
 	uint32_t css_lastround_minrtt;



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