public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Ingo Molnar <mingo@elte.hu>
Cc: Steven Rostedt <rostedt@goodmis.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Peter Zijlstra <peterz@infradead.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>
Subject: Re: [BUG] lockup with the latest kernel
Date: Fri, 28 Aug 2009 15:59:30 +0900	[thread overview]
Message-ID: <4A978052.6000908@kernel.org> (raw)
In-Reply-To: <20090828063603.GA21420@elte.hu>

Hello,

Ingo Molnar wrote:
>> Eh... don't have earlier AMD doc and gotta go now.  Can somebody 
>> please check?  But it looks like we can deadlock by simply sending 
>> RESCHEDULE_VECTOR more than two times while holding rq lock on 
>> AMD?
> 
> We poll ICR in the send-IPI logic before sending it out - so this 
> shouldnt happen. The restrictions above should at most cause extra 
> polling latency (i.e. it's a performance detail, not a lockup 
> source). See all the *wait_icr_idle() methods in the IPI sending 
> logic in arch/x86.

Ah... good.  I'm not all that familiar with the area so I was kind of
shooting in the dark.

> Neither TLB flushes nor reschedule IPIs are idempotent, so if this 
> was broken and if we lost requested events on remote CPUs we'd 
> notice it rather quickly via TLB flush related hangs or scheduling 
> latencies or lost wakeups, on a rather large category of CPUs.

But it still looks like we can quite easily fall into deadlock when
there are multiple cpus.  cpu0 holding rq_lock and sends RESCHEUDLE,
cpu1 waiting on rq_lock with irq disabled and some other cpus already
sent three other IPIs to cpu1 then cpu0 will lock up on the BUSY bit
when it tries to send RESCHEDULE, no?

> I think Linus's suggestion that it's the zero mask quirk on certain 
> older CPUs that is causing problems on that system should be 
> examined ... does .31-rc8 work fine?

Yeap, it would be great if that's the case.

Thanks.

-- 
tejun

  reply	other threads:[~2009-08-28  6:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-19 15:49 [BUG] lockup with the latest kernel Steven Rostedt
2009-08-19 15:50 ` Steven Rostedt
2009-08-19 16:18 ` Andrew Morton
2009-08-27 22:41 ` Steven Rostedt
2009-08-27 22:45   ` Steven Rostedt
2009-08-28  2:46   ` Tejun Heo
2009-08-28  2:52     ` Tejun Heo
2009-08-28  6:36       ` Ingo Molnar
2009-08-28  6:59         ` Tejun Heo [this message]
2009-08-28  4:05     ` Linus Torvalds
2009-08-28 16:15       ` Steven Rostedt
2009-08-28 18:33         ` Steven Rostedt
2009-09-09  2:29           ` 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=4A978052.6000908@kernel.org \
    --to=tj@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.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