From: Matthieu Baerts <matttbe@kernel.org>
To: Paolo Abeni <pabeni@redhat.com>, mptcp@lists.linux.dev
Subject: Re: [PATCH mptcp-net 0/2] mptcp: "fix suspicious RCU usage" warnings
Date: Thu, 17 Oct 2024 11:47:21 +0200 [thread overview]
Message-ID: <17059f40-2948-4db4-82ce-0c82f7d2e492@kernel.org> (raw)
In-Reply-To: <fab2f100-afa1-4b15-b7d8-b8ca267e959f@redhat.com>
Hi Paolo,
On 17/10/2024 11:38, Paolo Abeni wrote:
> On 10/16/24 21:05, Matthieu Baerts (NGI0) wrote:
>> Enabling PROVE_RCU_LIST (and RCU_EXPERT) shows list_for_each_entry_rcu()
>> from mptcp_sched_find() not being used with RCU read lock held.
>>
>> The first patch is a fix for -net. The other one is for a commit that is
>> only in our tree.
>>
>> Link: https://lore.kernel.org/20241016011144.3058445-1-kuba@kernel.org
>> Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
>> ---
>> Matthieu Baerts (NGI0) (2):
>> mptcp: init: protect sched with rcu_read_lock
>> Squash to "bpf: Add bpf_mptcp_sched_ops"
>>
>> net/mptcp/bpf.c | 10 +++++++---
>> net/mptcp/protocol.c | 2 ++
>> 2 files changed, 9 insertions(+), 3 deletions(-)
>> ---
>> base-commit: baccd7675477b1db387aa71b48c3312b5fb67a5d
>> change-id: 20241016-mptcp-sched-find-rcu-649ce3399334
>>
>> Best regards,
>
> Only slightly related, but mptcp_get_available_schedulers() currently
> acquires both the rcu and the sched_list lock. I think the latter is not
> needed and should be dropped.
Good point, the list is not modified.
I can send a patch for that.
(sorry, I should not have applied these patches that quickly, I was busy
adding 'debug' support for the BPF tests in our CI, and I didn't think
it was too quick)
Cheers,
Matt
--
Sponsored by the NGI0 Core fund.
prev parent reply other threads:[~2024-10-17 9:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-16 19:05 [PATCH mptcp-net 0/2] mptcp: "fix suspicious RCU usage" warnings Matthieu Baerts (NGI0)
2024-10-16 19:05 ` [PATCH mptcp-net 1/2] mptcp: init: protect sched with rcu_read_lock Matthieu Baerts (NGI0)
2024-10-17 1:28 ` Geliang Tang
2024-10-16 19:05 ` [PATCH mptcp-net 2/2] Squash to "bpf: Add bpf_mptcp_sched_ops" Matthieu Baerts (NGI0)
2024-10-17 1:29 ` Geliang Tang
2024-10-17 8:09 ` Matthieu Baerts
2024-10-16 20:11 ` [PATCH mptcp-net 0/2] mptcp: "fix suspicious RCU usage" warnings MPTCP CI
2024-10-17 9:06 ` Matthieu Baerts
2024-10-17 9:38 ` Paolo Abeni
2024-10-17 9:47 ` Matthieu Baerts [this message]
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=17059f40-2948-4db4-82ce-0c82f7d2e492@kernel.org \
--to=matttbe@kernel.org \
--cc=mptcp@lists.linux.dev \
--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