MPTCP Linux Development
 help / color / mirror / Atom feed
From: Paolo Abeni <pabeni@redhat.com>
To: "Matthieu Baerts (NGI0)" <matttbe@kernel.org>, mptcp@lists.linux.dev
Subject: Re: [PATCH mptcp-net 0/2] mptcp: "fix suspicious RCU usage" warnings
Date: Thu, 17 Oct 2024 11:38:10 +0200	[thread overview]
Message-ID: <fab2f100-afa1-4b15-b7d8-b8ca267e959f@redhat.com> (raw)
In-Reply-To: <20241016-mptcp-sched-find-rcu-v1-0-5e9af4fbce11@kernel.org>

Hi,

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.

Cheers,

Paolo


  parent reply	other threads:[~2024-10-17  9:38 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 [this message]
2024-10-17  9:47   ` Matthieu Baerts

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=fab2f100-afa1-4b15-b7d8-b8ca267e959f@redhat.com \
    --to=pabeni@redhat.com \
    --cc=matttbe@kernel.org \
    --cc=mptcp@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