Linux Kernel Mentees Archive on lore.kernel.org
 help / color / Atom feed
From: Madhuparna Bhowmik <madhuparnabhowmik04@gmail.com>
To: Wei Liu <wei.liu@kernel.org>
Cc: "Paul E. McKenney" <paulmck@kernel.org>,
	paul@xen.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Joel Fernandes <joel@joelfernandes.org>,
	xen-devel@lists.xenproject.org,
	linux-kernel-mentees@lists.linuxfoundation.org,
	davem@davemloft.net
Subject: Re: [Linux-kernel-mentees] [PATCH] net: xen-netbank: hash.c: Use built-in RCU list checking
Date: Wed, 15 Jan 2020 21:16:21 +0530
Message-ID: <CAF65HP2gnDYud99DY51JMXGKaNUC5JNZgPWB8bgno+gjoVffvA@mail.gmail.com> (raw)
In-Reply-To: <20200115150426.svapzpux2tbbgvmn@debian>

[-- Attachment #1.1: Type: text/plain, Size: 893 bytes --]

On Wed, Jan 15, 2020 at 8:34 PM Wei Liu <wei.liu@kernel.org> wrote:

> On Wed, Jan 15, 2020 at 07:36:38PM +0530, Madhuparna Bhowmik wrote:
> [...]
> >
> > > The surrounding code makes it pretty clear that the lock is already
> held
> > > by the time list_for_each_entry_rcu is called, yet the checking
> involved
> > > in lockdep_is_held is not trivial, so I'm afraid I don't consider this
> a
> > > strict improvement over the existing code.
> > >
> > > Actually,  we want to make CONFIG_PROVE_LIST_RCU enabled by default.
>
> I think you meant CONFIG_PROVE_RCU_LIST.
>
> I am sorry about this. Yes, I meant  CONFIG_PROVE_RCU_LIST.

> And if the cond argument is not passed when the usage of
> > list_for_each_entry_rcu()
> > is outside of rcu_read_lock(), it will lead to a false positive.
> > Therefore, I think this patch is required.
>
> Fair enough.
>
> Thank you,
Madhuparna


> Wei.
>

[-- Attachment #1.2: Type: text/html, Size: 1638 bytes --]

<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jan 15, 2020 at 8:34 PM Wei Liu &lt;<a href="mailto:wei.liu@kernel.org">wei.liu@kernel.org</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed, Jan 15, 2020 at 07:36:38PM +0530, Madhuparna Bhowmik wrote:<br>
[...]<br>
&gt; <br>
&gt; &gt; The surrounding code makes it pretty clear that the lock is already held<br>
&gt; &gt; by the time list_for_each_entry_rcu is called, yet the checking involved<br>
&gt; &gt; in lockdep_is_held is not trivial, so I&#39;m afraid I don&#39;t consider this a<br>
&gt; &gt; strict improvement over the existing code.<br>
&gt; &gt;<br>
&gt; &gt; Actually,  we want to make CONFIG_PROVE_LIST_RCU enabled by default.<br>
<br>
I think you meant CONFIG_PROVE_RCU_LIST.<br>
<br></blockquote><div>I am sorry about this. Yes, I meant  CONFIG_PROVE_RCU_LIST.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
&gt; And if the cond argument is not passed when the usage of<br>
&gt; list_for_each_entry_rcu()<br>
&gt; is outside of rcu_read_lock(), it will lead to a false positive.<br>
&gt; Therefore, I think this patch is required.<br>
<br>
Fair enough.<br>
<br></blockquote><div>Thank you,</div><div>Madhuparna</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Wei.<br>
</blockquote></div></div>

[-- Attachment #2: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

      reply index

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-15 12:41 madhuparnabhowmik04
2020-01-15 13:56 ` Wei Liu
2020-01-15 14:06   ` Madhuparna Bhowmik
2020-01-15 15:04     ` Wei Liu
2020-01-15 15:46       ` Madhuparna Bhowmik [this message]

Reply instructions:

You may reply publically 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=CAF65HP2gnDYud99DY51JMXGKaNUC5JNZgPWB8bgno+gjoVffvA@mail.gmail.com \
    --to=madhuparnabhowmik04@gmail.com \
    --cc=davem@davemloft.net \
    --cc=joel@joelfernandes.org \
    --cc=linux-kernel-mentees@lists.linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=paul@xen.org \
    --cc=paulmck@kernel.org \
    --cc=wei.liu@kernel.org \
    --cc=xen-devel@lists.xenproject.org \
    /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

Linux Kernel Mentees Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-kernel-mentees/0 linux-kernel-mentees/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-kernel-mentees linux-kernel-mentees/ https://lore.kernel.org/linux-kernel-mentees \
		linux-kernel-mentees@lists.linuxfoundation.org
	public-inbox-index linux-kernel-mentees

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.linuxfoundation.lists.linux-kernel-mentees


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git