public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Shreyas B Prabhu <shreyas@linux.vnet.ibm.com>
To: Steven Rostedt <rostedt@goodmis.org>,
	Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, mingo@redhat.com,
	aneesh.kumar@linux.vnet.ibm.com, paulmck@linux.vnet.ibm.com,
	preeti@linux.vnet.ibm.com, mgorman@suse.de, namhyung@kernel.org,
	lizf@cn.fujitsu.com, acme@redhat.com
Subject: Re: [PATCH RESEND 0/3] tracing/mm: Fix suspicious rcu_dereference_check() usage warnings
Date: Wed, 13 May 2015 13:17:06 +0530	[thread overview]
Message-ID: <5553017A.2080905@linux.vnet.ibm.com> (raw)
In-Reply-To: <20150512165446.6daf5a4a@gandalf.local.home>



On Wednesday 13 May 2015 02:24 AM, Steven Rostedt wrote:
> On Tue, 12 May 2015 13:36:01 -0700
> Andrew Morton <akpm@linux-foundation.org> wrote:
> 
>> On Tue, 12 May 2015 16:03:51 -0400 Steven Rostedt <rostedt@goodmis.org> wrote:
>>
>>> On Tue, 12 May 2015 12:59:26 +0530
>>> Shreyas B Prabhu <shreyas@linux.vnet.ibm.com> wrote:
>>>
>>>> Hi Steven,
>>>> On closer look, there is no particular maintainer who picks changes to
>>>> this file. Can you please pick these up?
>>>
>>> Perhaps Andrew Morton?
>>>
>>> No problem, I can take these too.
>>>
>>
>> I grabbed them, thanks.
>>

Thanks Andrew.

>>> +	TP_CONDITION(cpu_online(smp_processor_id())),
>>
>> Are we sure these can't generate check_preemption_disabled() warnings? 
>> Is there some reason why all these calls always occur with preemption
>> disabled?
> 
> Good catch. I don't think the code does.
> 
> Now, I'm not sure if we should just add a raw_smp_processor_id(). The
> idea is just to make sure that the CPU we are running on is online,
> because it is possible to call theses trace points when the CPU is
> going offline. If that happens, then there's a race with RCU.
> 
> Since a task can not be migrated to an offline CPU, we don't need to
> worry about the cpu_online(smp_processor_id()) returning a false
> positive. A false negative would just skip a tracepoint, but I'm not
> sure that is possible either.
> 
> In any case, comments should also be added to why the condition is
> there.
> 
I'll send a patch adding the comments.

Thanks,
Shreyas


  reply	other threads:[~2015-05-13  7:47 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-08 17:20 [PATCH RESEND 0/3] tracing/mm: Fix suspicious rcu_dereference_check() usage warnings Shreyas B. Prabhu
2015-05-08 17:20 ` [PATCH RESEND 1/3] tracing/mm: Don't trace kmem_cache_free on offline cpus Shreyas B. Prabhu
2015-05-08 17:20 ` [PATCH RESEND 2/3] tracing/mm: Don't trace mm_page_free " Shreyas B. Prabhu
2015-05-08 17:20 ` [PATCH RESEND 3/3] tracing/mm: Don't trace mm_page_pcpu_drain " Shreyas B. Prabhu
2015-05-12  7:29 ` [PATCH RESEND 0/3] tracing/mm: Fix suspicious rcu_dereference_check() usage warnings Shreyas B Prabhu
2015-05-12 20:03   ` Steven Rostedt
2015-05-12 20:36     ` Andrew Morton
2015-05-12 20:54       ` Steven Rostedt
2015-05-13  7:47         ` Shreyas B Prabhu [this message]
2015-05-14 20:08           ` Andrew Morton
2015-05-14 20:38             ` Steven Rostedt

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=5553017A.2080905@linux.vnet.ibm.com \
    --to=shreyas@linux.vnet.ibm.com \
    --cc=acme@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=aneesh.kumar@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizf@cn.fujitsu.com \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=paulmck@linux.vnet.ibm.com \
    --cc=preeti@linux.vnet.ibm.com \
    --cc=rostedt@goodmis.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
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