From: Ingo Molnar <mingo@elte.hu>
To: Li Zefan <lizf@cn.fujitsu.com>
Cc: Jaswinder Singh Rajput <jaswinder@kernel.org>,
Nick Piggin <npiggin@suse.de>,
Rusty Russell <rusty@rustcorp.com.au>,
Mike Travis <travis@sgi.com>, LKML <linux-kernel@vger.kernel.org>,
Suresh Siddha <suresh.b.siddha@intel.com>,
"Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
Subject: Re: [BUG] kernel BUG at arch/x86/kernel/tlb_32.c:130!
Date: Tue, 20 Jan 2009 09:29:46 +0100 [thread overview]
Message-ID: <20090120082946.GC31473@elte.hu> (raw)
In-Reply-To: <49758937.5070300@cn.fujitsu.com>
* Li Zefan <lizf@cn.fujitsu.com> wrote:
> Ingo Molnar wrote:
> > * Ingo Molnar <mingo@elte.hu> wrote:
> >
> >> * Li Zefan <lizf@cn.fujitsu.com> wrote:
> >>
> >>> I was using mmotm 2009-01-16-16-18, and I ran into this BUG,
> >>> the line is:
> >>> BUG_ON(cpumask_empty(cpumask));
> >>>
> >>> I suspect it is caused by:
> >>>
> >>> commit 4595f9620cda8a1e973588e743cf5f8436dd20c6
> >>> Author: Rusty Russell <rusty@rustcorp.com.au>
> >>> Date: Sat Jan 10 21:58:09 2009 -0800
> >>>
> >>> x86: change flush_tlb_others to take a const struct cpumask
> >>>
> >>> Impact: reduce stack usage, use new cpumask API.
> >> Jaswinder reported a similar crash.
> >>
> >> Mike, Rusty, what's going on with this commit? Why does this code:
> >>
> >> + if (cpumask_any_but(&mm->cpu_vm_mask, smp_processor_id()) < nr_cpu_ids)
> >> + flush_tlb_others(&mm->cpu_vm_mask, mm, TLB_FLUSH_ALL);
> >>
> >> Assume that mm->cpu_vm_mask wont change? TLB flushes go async and the
> >> MM's schedulability is not locked during that. I.e. mm->cpu_vm_mask can
> >> change under you while the TLB flush IPIs are flying around - while when
> >> the cpumask was passed on-stack this wouldnt happen.
> >
> > okay, a testsystem of mine just triggered this crash too.
> >
> > Li Zefan, Jaswinder, does the patch below fix it for you?
> >
>
> I'll test it, but I have to run for several hours to confirm it, since
> the bug is not easy to trigger. :)
yes. It triggered on an old 32-bit dual-socket HyperThreading system for
me and that is because HyperThreading is very good at triggering narrow
SMP races. (which this one certainly is)
(I'd expect Nehalem to trigger this TLB flushing race more easily too,
where HyperThreading made a comeback.)
Ingo
next prev parent reply other threads:[~2009-01-20 8:30 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-20 6:29 [BUG] kernel BUG at arch/x86/kernel/tlb_32.c:130! Li Zefan
2009-01-20 7:54 ` Ingo Molnar
2009-01-20 8:17 ` Ingo Molnar
2009-01-20 8:20 ` Li Zefan
2009-01-20 8:29 ` Ingo Molnar [this message]
2009-01-20 13:44 ` Jaswinder Singh Rajput
2009-01-21 0:44 ` Li Zefan
2009-01-21 1:01 ` Jaswinder Singh Rajput
2009-01-20 18:17 ` Mike Travis
2009-01-20 7:56 ` Laurent Riffard
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=20090120082946.GC31473@elte.hu \
--to=mingo@elte.hu \
--cc=jaswinder@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lizf@cn.fujitsu.com \
--cc=npiggin@suse.de \
--cc=rusty@rustcorp.com.au \
--cc=suresh.b.siddha@intel.com \
--cc=travis@sgi.com \
--cc=venkatesh.pallipadi@intel.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;
as well as URLs for NNTP newsgroup(s).