From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gandalf.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id D72A95A027F for ; Wed, 21 Feb 2024 22:46:00 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202312; t=1708551955; bh=B1ugmHdpEkr1bkOeU4YWQ43V9bLQ2gUWwzfFwZCMOJg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=EMgDALzzhUYewOvMCKZQdU+UwGrwCjQxZjhP9g0Ca+tAxhLcXG7sbmsLT/Cnex4Ek Ln1kxbZHFV+AV3HeQqDlpyOfrui5YqL/VmCUzcdHEDbYEnPeFApPOP2cHkyZZY9GBT kutprFE/ZWpQesRG6gQImzp8bQ8P6RfDX6ZKeoH/V2RIgJmxBoitslhYhY5t7QvMEH X9WJXTCKzx23+TlJ53Wo2VPNT2t7zX3xoqCZCn23vMN3E9lGU0lxkM1CrVZ87FKjaz qSNJ1bYFHI/+1wO9QWPtmyik0Mt7vZn9PhZimkF4/h5vEiVHkCfXV901wIVwp5d0Gh IQGiJ5HMJrDNQ== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4Tg8wM0m7Zz4wyf; Thu, 22 Feb 2024 08:45:55 +1100 (AEDT) Date: Thu, 22 Feb 2024 08:42:58 +1100 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH 2/6] tcp: Don't stop refilling socket pool if we find a filled entry Message-ID: References: <20240219075651.1360229-1-david@gibson.dropbear.id.au> <20240219075651.1360229-3-david@gibson.dropbear.id.au> <20240221220849.685474d9@elisabeth> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="GZAiGV1LUSPjIM23" Content-Disposition: inline In-Reply-To: <20240221220849.685474d9@elisabeth> Message-ID-Hash: NJK4Z4PI2ORAKJQINKDBPFDDXP5GYWG3 X-Message-ID-Hash: NJK4Z4PI2ORAKJQINKDBPFDDXP5GYWG3 X-MailFrom: dgibson@gandalf.ozlabs.org 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: 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: --GZAiGV1LUSPjIM23 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Feb 21, 2024 at 10:08:49PM +0100, Stefano Brivio wrote: > On Mon, 19 Feb 2024 18:56:47 +1100 > David Gibson wrote: >=20 > > Currently tcp_sock_refill_pool() stops as soon as it finds an entry in = the > > pool with a valid fd. This appears to makes sense: we always use fds f= rom > > the front of the pool, so if we find a filled one, the rest of the pool > > should be filled as well. > >=20 > > However, that's not quite correct. If a previous refill hit errors try= ing > > to open new sockets, it could leave gaps between blocks of valid fds. W= e're > > going to add some changes that could make that more likely. >=20 > Uh oh, good catch, I didn't think of the possibility that with 3/6 we > could otherwise stop in the middle of a block of "empty" slots, with > filled slots occurring after them. Right. The consequences aren't particularly dire if we get this wrong: we don't fill the pool as full as we should, but we should still have fds to work with. --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --GZAiGV1LUSPjIM23 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmXWbkoACgkQzQJF27ox 2Gf2HRAAkT6NAWyy/7p6X2C608tHVnXNo93sjaq4CmKKzXeAE77kRi5JcqxkBn/y ww2E2x1Dalqh2tb3T1IBeUM1+NP8p1BMREDXZVrF45LQhezLplQzAam4Jqe/IgNT SgI89d5EhW4dtgBGATzng5EQKs7vyAUTtc36e+2I1Q4rYrF0sGeb96v9zTcfJbFT MRqJKdpsrpGR9XgAfBKdXLYu+gJr96aGh/QbeN+bSAcb645vGuqgRZWMlieot1J8 vmP/JmUfFlSb8eZTst7sJIrfwA8eTw2cxbANCnx3T/qGfzlvEC8ecXmAYyU46QZp h79csjzoYbE8ghqzMCq/HSVQB0E/ivoDdrGIKiGnn5mwAtzmtETOmpMI09uISds+ 6+pwuFE0y26RH3fwhn+QvcMB7mj7L7u/KmBAbx/WvdWth0ykw0Qnwpohghp0OgCF 4juzMizqNqh9TeZjeILnqcRHS0miJI7Fb6TzXpuR9qajDP66aAtBsx19BCc7OpRF U8+dbiCFotlJ5BuSkkaidx4AY1r6zarNZil4xCSkczZo0OLcD2jlzhxW1K8HcY59 066T0w7ea4v1+8GGQBbi1F6VicITNfSxn1/pepAk4n51ITLAm7dDx8yCf/JmRSPm 5EysYBYGGvgIXLE/QxgxjScQqYoDXuLBRSwg9MjFGTKAT4PUQXM= =X6FL -----END PGP SIGNATURE----- --GZAiGV1LUSPjIM23--