public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Suresh Siddha <suresh.b.siddha@intel.com>
Cc: Venkatesh Pallipadi <venki@google.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Heiko Carstens <heiko.carstens@de.ibm.com>,
	Ingo Molnar <mingo@elte.hu>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Jens Axboe <axboe@kernel.dk>
Subject: Re: [PATCH] generic-ipi: fix deadlock in __smp_call_function_single
Date: Tue, 14 Sep 2010 10:03:47 +0200	[thread overview]
Message-ID: <1284451427.2275.462.camel@laptop> (raw)
In-Reply-To: <1284400941.2684.19.camel@sbsiddha-MOBL3.sc.intel.com>

On Mon, 2010-09-13 at 11:02 -0700, Suresh Siddha wrote:
> On Sat, 2010-09-11 at 09:42 -0700, Venkatesh Pallipadi wrote:
> > Also, as we don't have rq lock around this point, it seems possible
> > that the CPU that was busy and wants to kick idle load balance on
> > remote CPU, could have become idle and nominated itself as idle load
> > balancer.
> 
> A busy cpu (currently running something -- one task on the rq atleast)
> can't become idle in the middle of trigger_load_balance().
> 
> What might be happening is similar what you said but the opposite of it.
> 
> cpu-x is idle which is also ilb_cpu
> got a scheduler tick during idle
> and the nohz_kick_needed() in trigger_load_balance() checks for
> rq_x->nr_running which might not be zero (because of someone waking a
> task on this rq etc) and this leads to the situation of the cpu-x
> sending a kick to itself.

So what patches are we going to merge?

I share Heiko's opinion on that its somewhat surprising to have
__smp_call_function_single() differ in this detail from
smp_call_function_single() and think that merging his patch would be
good in that respect. But Andrew seemed to have reservations.

We can also merge either my or Suresh's patch (which I think makes
sense, but is kinda subtle) to avoid the needless self kick.

Hmm?

  reply	other threads:[~2010-09-14  8:04 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-09 13:50 [PATCH] generic-ipi: fix deadlock in __smp_call_function_single Heiko Carstens
2010-09-10 11:06 ` Peter Zijlstra
2010-09-10 11:23   ` Jens Axboe
2010-09-10 11:47     ` Heiko Carstens
2010-09-10 15:47       ` [tip:core/urgent] generic-ipi: Fix " tip-bot for Heiko Carstens
2010-09-11  0:28   ` [PATCH] generic-ipi: fix " Andrew Morton
2010-09-11  9:20     ` Peter Zijlstra
2010-09-11 16:42       ` Venkatesh Pallipadi
2010-09-13  8:08         ` Heiko Carstens
2010-09-13 18:02         ` Suresh Siddha
2010-09-14  8:03           ` Peter Zijlstra [this message]
2010-09-14 11:19             ` Heiko Carstens
2010-09-17 22:12               ` Suresh Siddha
2010-09-18 15:18                 ` Peter Zijlstra
2010-09-21 14:13           ` [tip:sched/urgent] sched: Fix nohz balance kick tip-bot for Suresh Siddha
2010-09-26  8:42     ` [PATCH] generic-ipi: fix deadlock in __smp_call_function_single Ingo Molnar
2010-09-26 12:59       ` Heiko Carstens
2010-09-26 16:23         ` Ingo Molnar

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=1284451427.2275.462.camel@laptop \
    --to=peterz@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=axboe@kernel.dk \
    --cc=heiko.carstens@de.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=suresh.b.siddha@intel.com \
    --cc=venki@google.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