From: Eric Dumazet <edumazet@google.com>
To: "David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>
Cc: netdev@vger.kernel.org, eric.dumazet@gmail.com,
Eric Dumazet <edumazet@google.com>
Subject: [PATCH net 0/2] rfs: annotate lockless accesses
Date: Fri, 2 Jun 2023 16:31:39 +0000 [thread overview]
Message-ID: <20230602163141.2115187-1-edumazet@google.com> (raw)
rfs runs without locks held, so we should annotate
read and writes to shared variables.
It should prevent compilers forcing writes
in the following situation:
if (var != val)
var = val;
A compiler could indeed simply avoid the conditional:
var = val;
This matters if var is shared between many cpus.
Eric Dumazet (2):
rfs: annotate lockless accesses to sk->sk_rxhash
rfs: annotate lockless accesses to RFS sock flow table
include/linux/netdevice.h | 7 +++++--
include/net/sock.h | 18 +++++++++++++-----
net/core/dev.c | 6 ++++--
3 files changed, 22 insertions(+), 9 deletions(-)
--
2.41.0.rc0.172.g3f132b7071-goog
next reply other threads:[~2023-06-02 16:31 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-02 16:31 Eric Dumazet [this message]
2023-06-02 16:31 ` [PATCH net 1/2] rfs: annotate lockless accesses to sk->sk_rxhash Eric Dumazet
2023-06-02 20:20 ` Kuniyuki Iwashima
2023-06-05 22:52 ` Jakub Kicinski
2023-06-06 7:30 ` Eric Dumazet
2023-06-06 7:43 ` Eric Dumazet
2023-06-06 9:44 ` Simon Horman
2023-06-02 16:31 ` [PATCH net 2/2] rfs: annotate lockless accesses to RFS sock flow table Eric Dumazet
2023-06-02 20:27 ` Kuniyuki Iwashima
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=20230602163141.2115187-1-edumazet@google.com \
--to=edumazet@google.com \
--cc=davem@davemloft.net \
--cc=eric.dumazet@gmail.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).