From: David Gibson <david@gibson.dropbear.id.au>
To: Stefano Brivio <sbrivio@redhat.com>
Cc: passt-dev@passt.top
Subject: Re: [PATCH 1/5] tcp: Make a helper to refill each socket pool
Date: Sun, 15 Jan 2023 10:22:51 +1000 [thread overview]
Message-ID: <Y8NHW0c3slMJBM7Y@yekko> (raw)
In-Reply-To: <20230112190921.7a6bf18c@elisabeth>
[-- Attachment #1: Type: text/plain, Size: 1158 bytes --]
On Thu, Jan 12, 2023 at 07:09:21PM +0100, Stefano Brivio wrote:
> On Mon, 9 Jan 2023 11:50:22 +1100
> David Gibson <david@gibson.dropbear.id.au> wrote:
>
> > tcp_sock_refill() contains two near-identical loops to refill the IPv4
> > and IPv6 socket pools. In addition, if we get an error on the IPv4 pool
> > we exit early and won't attempt to refill the IPv6 pool. That doesn't seem
> > sensible, since these are essentially completely independent, and there
> > may be value to filling up either one without the other.
>
> Well, for the purposes of the single error condition that's checked
> there, they're not independent, in practice: if we just had a socket
> number that's too high, the next one will be, too. This is not formally
> guaranteed, though.
Ok, I've tweaked the commit message a bit.
> In any case, this is indeed more elegant, and also drops a
> 'return -EIO' which doesn't really match the "Return: 0" comment.
>
--
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
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2023-01-15 0:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-09 0:50 [PATCH 0/5] Cleanups to tcp socket pool handling David Gibson
2023-01-09 0:50 ` [PATCH 1/5] tcp: Make a helper to refill each socket pool David Gibson
2023-01-12 18:09 ` Stefano Brivio
2023-01-15 0:22 ` David Gibson [this message]
2023-01-09 0:50 ` [PATCH 2/5] tcp: Split init and ns cases for tcp_sock_refill() David Gibson
2023-01-09 0:50 ` [PATCH 3/5] tcp: Move socket pool declarations around David Gibson
2023-01-12 18:09 ` Stefano Brivio
2023-01-15 0:26 ` David Gibson
2023-01-09 0:50 ` [PATCH 4/5] tcp: Split pool lookup from creating new sockets in tcp_conn_new_sock() David Gibson
2023-01-09 0:50 ` [PATCH 5/5] tcp: Improve handling of fallback if socket pool is empty on new splice David Gibson
2023-01-12 18:09 ` Stefano Brivio
2023-01-15 0:31 ` David Gibson
2023-01-23 17:47 ` Stefano Brivio
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Y8NHW0c3slMJBM7Y@yekko \
--to=david@gibson.dropbear.id.au \
--cc=passt-dev@passt.top \
--cc=sbrivio@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://passt.top/passt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).