From: Qingjie Xing <xqjcool@gmail.com>
To: edumazet@google.com
Cc: davem@davemloft.net, dhowells@redhat.com, fw@strlen.de,
johannes@sipsolutions.net, keescook@chromium.org,
kuba@kernel.org, kuniyu@amazon.com, linux-kernel@vger.kernel.org,
netdev@vger.kernel.org, pabeni@redhat.com,
pctammela@mojatatu.com, xqjcool@gmail.com
Subject: Re: [PATCH] netlink: Fix the netlink socket malfunction due to concurrency
Date: Sat, 19 Aug 2023 11:24:36 -0700 [thread overview]
Message-ID: <20230819182436.2369-1-xqjcool@gmail.com> (raw)
In-Reply-To: <CANn89iJCDYteM_1SQ-h2=htUAE4FqrBAak0kHt_Z990XYZThzQ@mail.gmail.com>
This piece of code has been present since the Linux code v2.6.12 was
incorporated into Git management.
I believe this modification could potentially address the concurrent issue
we've been discussing.
In netlink_rcv_wake(), as described in [2], the socket's receive queue is
empty, indicated by sk_rmem_alloc being 0. At this point, concurrent
netlink_attachskb() calls netlink_overrun(). In this critical state, the
sk_rmem_alloc of the socket will not instantly transition from 0 to a
value greater than sk_rcvbuf.
next prev parent reply other threads:[~2023-08-19 22:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-18 18:37 [PATCH] netlink: Fix the netlink socket malfunction due to concurrency Qingjie Xing
2023-08-18 18:57 ` Eric Dumazet
2023-08-19 18:04 ` Qingjie Xing
2023-08-19 18:24 ` Qingjie Xing [this message]
2023-08-19 20:17 ` Qingjie Xing
2023-08-23 16:43 ` Further Elaboration on this patch Qingjie Xing
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=20230819182436.2369-1-xqjcool@gmail.com \
--to=xqjcool@gmail.com \
--cc=davem@davemloft.net \
--cc=dhowells@redhat.com \
--cc=edumazet@google.com \
--cc=fw@strlen.de \
--cc=johannes@sipsolutions.net \
--cc=keescook@chromium.org \
--cc=kuba@kernel.org \
--cc=kuniyu@amazon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pctammela@mojatatu.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).