public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Stefano Garzarella <sgarzare@redhat.com>
To: Laurence Rowe <laurencerowe@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>,
	 Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>,
	 Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
	virtualization@lists.linux.dev,  netdev@vger.kernel.org,
	Bobby Eshleman <bobbyeshleman@meta.com>
Subject: Re: [PATCH net-next v2] vsock: avoid timeout for non-blocking accept() with empty backlog
Date: Fri, 3 Apr 2026 13:54:45 +0200	[thread overview]
Message-ID: <ac-qD9dQU_JB9VvY@sgarzare-redhat> (raw)
In-Reply-To: <20260402204918.130395-1-laurencerowe@gmail.com>

On Thu, Apr 02, 2026 at 01:49:18PM -0700, Laurence Rowe wrote:
>A common pattern in epoll network servers is to eagerly accept all
>pending connections from the non-blocking listening socket after
>epoll_wait indicates the socket is ready by calling accept in a loop
>until EAGAIN is returned indicating that the backlog is empty.
>
>Scheduling a timeout for a non-blocking accept with an empty backlog
>meant AF_VSOCK sockets used by epoll network servers incurred hundreds
>of microseconds of additional latency per accept loop compared to
>AF_INET or AF_UNIX sockets.
>
>Signed-off-by: Laurence Rowe <laurencerowe@gmail.com>
>Reviewed-by: Bobby Eshleman <bobbyeshleman@meta.com>
>---
>
>Patch v2 with feedback from Stefano Garzarella and Bobby Eshleman:
>
>- Move prepare_to_wait before release_sock to match previous behaviour.
>
>- Simplify not connected case.

Thanks for addressing them, now LGTM!

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>


  reply	other threads:[~2026-04-03 11:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-02 20:49 [PATCH net-next v2] vsock: avoid timeout for non-blocking accept() with empty backlog Laurence Rowe
2026-04-03 11:54 ` Stefano Garzarella [this message]
2026-04-07  1:40 ` patchwork-bot+netdevbpf

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=ac-qD9dQU_JB9VvY@sgarzare-redhat \
    --to=sgarzare@redhat.com \
    --cc=bobbyeshleman@meta.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=laurencerowe@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=virtualization@lists.linux.dev \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox