From: Salvatore Dipietro <dipiets@amazon.com>
To: <edumazet@google.com>
Cc: <alisaidi@amazon.com>, <benh@amazon.com>, <blakgeof@amazon.com>,
<davem@davemloft.net>, <dipietro.salvatore@gmail.com>,
<dipiets@amazon.com>, <dsahern@kernel.org>, <kuba@kernel.org>,
<netdev@vger.kernel.org>, <pabeni@redhat.com>
Subject: RE: [PATCH] tcp: disable tcp_autocorking for socket when TCP_NODELAY flag is set
Date: Wed, 13 Dec 2023 13:30:06 -0800 [thread overview]
Message-ID: <20231213213006.89142-1-dipiets@amazon.com> (raw)
In-Reply-To: <CANn89i+98ifRj9SJQbK+QJrCde2UJvWr1h31gAZSuxt4i_U=iw@mail.gmail.com>
> It looks like the above disables autocorking even after the userspace
> sets TCP_CORK. Am I reading it correctly? Is that expected?
I have tested a new version of the patch which can target only TCP_NODELAY.
Results using previous benchmark are identical. I will submit it in a new
patch version.
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
--- a/net/ipv4/tcp.c
+++ b/net/ipv4/tcp.c
@@ -716,7 +716,8 @@
tcp_mark_urg(tp, flags);
- if (tcp_should_autocork(sk, skb, size_goal)) {
+ if (!(nonagle & TCP_NAGLE_OFF) &&
+ tcp_should_autocork(sk, skb, size_goal)) {
/* avoid atomic op if TSQ_THROTTLED bit is already set */
if (!test_bit(TSQ_THROTTLED, &sk->sk_tsq_flags)) {
> Also I wonder about these 40ms delays, TCP small queue handler should
> kick when the prior skb is TX completed.
>
> It seems the issue is on the driver side ?
>
> Salvatore, which driver are you using ?
I am using ENA driver.
Eric can you please clarify where do you think the problem is?
next prev parent reply other threads:[~2023-12-13 21:30 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-08 18:20 [PATCH] tcp: disable tcp_autocorking for socket when TCP_NODELAY flag is set Salvatore Dipietro
2023-12-09 11:03 ` Eric Dumazet
2023-12-11 15:58 ` Hazem Mohamed Abuelfotoh
2023-12-12 10:41 ` Paolo Abeni
2023-12-12 11:29 ` Eric Dumazet
2023-12-12 10:57 ` Paolo Abeni
2023-12-13 14:10 ` Eric Dumazet
2023-12-13 19:00 ` Jakub Kicinski
2023-12-13 19:29 ` Eric Dumazet
2023-12-13 21:30 ` Salvatore Dipietro [this message]
2023-12-14 8:40 ` Eric Dumazet
2023-12-14 9:05 ` Eric Dumazet
2023-12-14 14:08 ` Eric Dumazet
2023-12-14 15:52 ` Geoff Blake
2023-12-14 16:07 ` Eric Dumazet
2024-01-17 21:26 ` [PATCH v2] tcp: Add memory barrier to tcp_push() Salvatore Dipietro
2024-01-17 21:58 ` Eric Dumazet
2024-01-17 23:16 ` [PATCH v3] " Salvatore Dipietro
2024-01-18 10:38 ` Paolo Abeni
2024-01-18 10:42 ` Eric Dumazet
2024-01-18 16:40 ` Jakub Kicinski
2024-01-18 17:46 ` Geoff Blake
2024-01-18 18:30 ` Paolo Abeni
2024-01-18 19:30 ` Geoff Blake
2024-01-19 13:33 ` Eric Dumazet
2024-04-17 7:33 ` Eric Dumazet
2024-04-22 16:16 ` Salvatore Dipietro
2023-12-13 10:40 ` [PATCH] tcp: disable tcp_autocorking for socket when TCP_NODELAY flag is set 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=20231213213006.89142-1-dipiets@amazon.com \
--to=dipiets@amazon.com \
--cc=alisaidi@amazon.com \
--cc=benh@amazon.com \
--cc=blakgeof@amazon.com \
--cc=davem@davemloft.net \
--cc=dipietro.salvatore@gmail.com \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@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.
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 NNTP newsgroup(s).