[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130510162340.GE22942@pd.tnic>
Date: Fri, 10 May 2013 18:23:40 +0200
From: Borislav Petkov <bp@...en8.de>
To: Frederic Weisbecker <fweisbec@...il.com>
Cc: Jiri Kosina <jkosina@...e.cz>, Tony Luck <tony.luck@...el.com>,
linux-kernel@...r.kernel.org, x86@...nel.org
Subject: Re: NOHZ: WARNING: at arch/x86/kernel/smp.c:123
native_smp_send_reschedule
On Fri, May 10, 2013 at 05:43:50PM +0200, Frederic Weisbecker wrote:
> Right. But this is adding a timer locally, from CPU 1 to CPU 1, as
> indicated in the trace with the "1 1" line. So the only way for
> this IPI to be self-sent is if the tick is stopped locally (cf:
> wake_up_full_nohz_cpu()).
>
> But the tick is not supposed to be stopped so early in a secondary CPU
> initialization. The tick can be stopped only from two places:
>
> 1) idle loop, but we haven't yet reached that place. cpu_idle() is
> called much later 2) interrupt exit, but interrupts are supposed to be
> disabled at this stage
Hmm, I see.
> So either interrupts are spuriously enabled early, or ts->tick_stopped
> is not correctly initialized.
Hmm, it can't be interrupts disabled because add_timer_on() does
spin_lock_irqsave() before calling wake_up_nohz_cpu()... Maybe something
like the below could help check this...
Although AFAICT, we're enabling interrupts much later in
start_secondary, even after we've set the bit in the online mask.
---
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c
index 9c73b51817e4..1b679b0fa57a 100644
--- a/arch/x86/kernel/smpboot.c
+++ b/arch/x86/kernel/smpboot.c
@@ -201,6 +201,8 @@ static void __cpuinit smp_callin(void)
*/
setup_vector_irq(smp_processor_id());
+ WARN_ON(!irqs_disabled());
+
/*
* Save our processor parameters. Note: this information
* is needed for clock calibration.
--
Regards/Gruss,
Boris.
Sent from a fat crate under my desk. Formatting is fine.
--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists