From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: passt.top; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=OH9YSmIk; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTPS id 8D7495A0271 for ; Tue, 18 Nov 2025 01:19:40 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1763425179; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pDi1sy67FUaKtZdp1QcIiUR/rbnjMh5hxR/lPFEeRuk=; b=OH9YSmIktvanf90/rxYY2HqsxcZ0TlI2/qigqP2n2dgmr/9TOYEzCgvVedXjW07OF8UzCC Kt8u3xGKMcONPhyVv2NyLIT/pPEd0W0G8gTk5imvzyfhwtq43b0XzpoKn43XkMwb9/BXkQ vj45YJteuHMFMBlRG8ouwYUVzPrxXrg= Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-576-EbLW_5LiMhSwDJ_N4v_D0Q-1; Mon, 17 Nov 2025 19:19:38 -0500 X-MC-Unique: EbLW_5LiMhSwDJ_N4v_D0Q-1 X-Mimecast-MFC-AGG-ID: EbLW_5LiMhSwDJ_N4v_D0Q_1763425177 Received: by mail-wm1-f71.google.com with SMTP id 5b1f17b1804b1-4779ecc3cc8so10206985e9.3 for ; Mon, 17 Nov 2025 16:19:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763425176; x=1764029976; h=content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lVmhOnTTdqu2Z2wG6ohbwIFQxZ/r9NsM2J+gnt0a6sU=; b=mis7h5Cq+dRUyq0X1nEmRNZ0NY1J4Clfed8m3qkXb5feZ5YuRQv6OMrv/J5MeodOiA tXF8NJyun4iKfZeQs9hHFyCJPfVfDd8cPK53XOI0yg5ZqbpblKBq8JcSx2zxWV+Fv2aW WSjwZx8Ah9z/R60RNlxxLkQyxkFVWVZlmNMeWLOzN/0lYD8vUg879a2Xz39ha+6phoGR kbjeecL2xtOHrfAeff7IAD8sZQd84Sehsxp62s/aNspuSeEw3KlavoetEmTFSNNj/75U UVmrb3eYrp1r/SQJim6DOYQP7lMd0wwEQOPFyaCsxOjy07/yK8bNOuXAMi4JT/azH2QC 28hQ== X-Forwarded-Encrypted: i=1; AJvYcCVSiVk7MQE06Sge+w3RitWCOUPh1eOkPX4fEB/Mty8CMfhy/pKIf05VashS1pUnkcJWLf5s6rdaG1w=@passt.top X-Gm-Message-State: AOJu0YzYY7RL8eQD9RpFJT52KDcmbJItstVCTM/m8OGYXxGE9mLyhWF9 AJ5VxJOmkcIqMjiNxcFAyt22BNKJyjc9ahRkmZ94ucGCCrE3IFR/xtiy6OWJ+QllsAN5VHpSAbR OIUsl949BUVoPr20uko1nGrAx80Etz2Xg9+dJj1vq3aeANPgGaoF6wgArkoLi+A== X-Gm-Gg: ASbGncuFFZT2kVn3CQa35v2bXIRommU0aCIwj/1PC8sCqV11K9VZn1HrvopUunZrjWB iRO5Of08KO1/LRUxW0a19/q7Sgu7jdct9QlwOhli13q/05UBKfetoTxEYGXvC04DoEULtcnFaHr aLdT/m1z5eMwDZR7ERWx68WaHUuWOP1y3kwhk5WuYpFP0oa21y5zjcANh8fc/J2l6Xn5zJzIKmb lgQPE+KN4iIYEMcXNnzl2khxUgkLbAzUCseBfKNHjsbTnuOTr/FAA4w0MxmzE2G2GXawpJ1FSq2 UsvA/4PB3BnCekESpwdP8T+yfZYkMjhfFQeJPq/b2FXLkqV5uSxgyTcI9blhINroyCVGkmQrzaB q3G9tN3qX0Hq414v32IGg X-Received: by 2002:a05:600c:350d:b0:475:dd59:d8d8 with SMTP id 5b1f17b1804b1-4778fe4f716mr136179285e9.8.1763425175889; Mon, 17 Nov 2025 16:19:35 -0800 (PST) X-Google-Smtp-Source: AGHT+IHxiDJyhy+asXXJIort5PBULjhUgiASr0mUXCDhcjvzkdxPrZ2mvxXRMHACddnHZfJ0dZsX3A== X-Received: by 2002:a05:600c:350d:b0:475:dd59:d8d8 with SMTP id 5b1f17b1804b1-4778fe4f716mr136179055e9.8.1763425175419; Mon, 17 Nov 2025 16:19:35 -0800 (PST) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [2a10:fc81:a806:d6a9::1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47787e8e6a1sm323375715e9.11.2025.11.17.16.19.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Nov 2025 16:19:34 -0800 (PST) Date: Tue, 18 Nov 2025 01:19:33 +0100 From: Stefano Brivio To: David Gibson Subject: Re: [PATCH v8 6/6] tcp: Clamp the retry timeout Message-ID: <20251118011933.5f61a686@elisabeth> In-Reply-To: References: <20251110093137.87705-7-yuhuang@redhat.com> <20251114010121.10dfb18a@elisabeth> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: SeZAT4bQCurWOjnker3ciemoHcPkXFExlg0qFJx8WTo_1763425177 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Message-ID-Hash: LWO7E2SBVMMGC647FF6WWPX4SSLDGUFV X-Message-ID-Hash: LWO7E2SBVMMGC647FF6WWPX4SSLDGUFV X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Yumei Huang , passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Fri, 14 Nov 2025 14:35:12 +1100 David Gibson wrote: > On Fri, Nov 14, 2025 at 11:05:51AM +0800, Yumei Huang wrote: > > On Fri, Nov 14, 2025 at 8:47=E2=80=AFAM David Gibson > > wrote: =20 > > > > > > On Fri, Nov 14, 2025 at 01:01:21AM +0100, Stefano Brivio wrote: =20 > > > > On Mon, 10 Nov 2025 21:56:39 +1100 > > > > David Gibson wrote: > > > > =20 > > > > > On Mon, Nov 10, 2025 at 05:31:37PM +0800, Yumei Huang wrote: =20 > > > > > > > > > > > @@ -2811,10 +2821,15 @@ void tcp_get_rto_params(struct ctx *c) > > > > > > v =3D read_file_integer(SYN_LINEAR_TIMEOUTS, SYN_LINEAR_TIMEO= UTS_DEFAULT); > > > > > > c->tcp.syn_linear_timeouts =3D MIN(v, MAX_SYNCNT); > > > > > > > > > > > > + v =3D read_file_integer(RTO_MAX_MS, RTO_MAX_MS_DEFAULT); > > > > > > + c->tcp.rto_max =3D MIN(DIV_ROUND_CLOSEST(v, 1000), INT_MAX); = =20 > > > > > > > > > > Possibly we should verify this is =3D> RTO_INIT. =20 > > > > > > > > As a sanity check, maybe, but I don't see any harmful effect if it'= s > > > > < RTO_INIT, right? So I'm not sure if we should. No preference from= my > > > > side really. =20 > > > > > > Sorry, describing this as >=3D RTO_INIT was misleading. What I'm > > > concerned about here is if the kernel value is set to 400ms, we'll > > > round it to... 0s. > > > > > > So, really what I'm concerned about is that we ensure this is > 0. = =20 > >=20 > > That's a good point. =20 >=20 > Actually, thinking about it, I wonder if makes more sense to always > round up to 1s, rather than to the nearest 1s. I guess so, yes. Using two seconds as timeout when the user configured 1400ms isn't necessarily less correct than using one second, and it simplifies things (we already have DIV_ROUND_UP()). --=20 Stefano