public inbox for mptcp@lists.linux.dev
 help / color / mirror / Atom feed
* [PATCH mptcp-next] Squash to "mptcp: better mptcp-level RTT estimator"
@ 2026-04-03 11:34 Matthieu Baerts (NGI0)
  2026-04-03 12:45 ` MPTCP CI
  2026-04-06 14:18 ` Matthieu Baerts
  0 siblings, 2 replies; 3+ messages in thread
From: Matthieu Baerts (NGI0) @ 2026-04-03 11:34 UTC (permalink / raw)
  To: MPTCP Upstream; +Cc: Matthieu Baerts (NGI0)

Address AI reviews:

- samples[0] is read without READ_ONCE, while the others are.

- prev_rtt_us is added but not used.

Link: https://lore.kernel.org/20260311024547.361027-1-kuba@kernel.org
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
---
 net/mptcp/protocol.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/net/mptcp/protocol.h b/net/mptcp/protocol.h
index 740f9d975719..98902ec4796d 100644
--- a/net/mptcp/protocol.h
+++ b/net/mptcp/protocol.h
@@ -449,7 +449,7 @@ static inline void mptcp_init_rtt_est(struct mptcp_sock *msk)
 
 static inline u32 mptcp_rtt_us_est(const struct mptcp_sock *msk)
 {
-	u32 rtt_us = msk->rcv_rtt_est.samples[0];
+	u32 rtt_us = READ_ONCE(msk->rcv_rtt_est.samples[0]);
 	int i;
 
 	/* Lockless access of collected samples. */
@@ -559,7 +559,6 @@ struct mptcp_subflow_context {
 	u32	map_data_len;
 	__wsum	map_data_csum;
 	u32	map_csum_len;
-	u32	prev_rtt_us;
 	u32	prev_rtt_seq;
 	u32	request_mptcp : 1,  /* send MP_CAPABLE */
 		request_join : 1,   /* send MP_JOIN */

---
base-commit: 7f76791a2c6b61a0e074bd908e731418ebc2ab5a
change-id: 20260403-mptcp-fix-better-mptcp-level-rtt-estimator-b63d2cb74d61

Best regards,
--  
Matthieu Baerts (NGI0) <matttbe@kernel.org>


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-04-06 14:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-03 11:34 [PATCH mptcp-next] Squash to "mptcp: better mptcp-level RTT estimator" Matthieu Baerts (NGI0)
2026-04-03 12:45 ` MPTCP CI
2026-04-06 14:18 ` Matthieu Baerts

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox