* [PATCH] Ignore bogus ACPI info for offline CPUs
@ 2007-05-19 14:22 Thomas Gleixner
2007-05-21 16:47 ` Darren Hart
0 siblings, 1 reply; 6+ messages in thread
From: Thomas Gleixner @ 2007-05-19 14:22 UTC (permalink / raw)
To: LKML; +Cc: Len Brown, Darren Hart, Ingo Molnar, Andrew Morton, Stable Team
Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
hang, because ACPI ignores the maxcpus setting and sends timer broadcast
info for the offline CPUs. This results in a stuck for ever call to
smp_call_function_single() on an offline CPU.
Ignore the bogus information and print a kernel error to remind ACPI
folks to fix it.
Affects 2.6.21 / 2.6.22-rc
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Index: linux-2.6.22-rc/kernel/time/tick-broadcast.c
===================================================================
--- linux-2.6.22-rc.orig/kernel/time/tick-broadcast.c
+++ linux-2.6.22-rc/kernel/time/tick-broadcast.c
@@ -244,11 +244,18 @@ void tick_broadcast_on_off(unsigned long
{
int cpu = get_cpu();
- if (cpu == *oncpu)
- tick_do_broadcast_on_off(&reason);
- else
- smp_call_function_single(*oncpu, tick_do_broadcast_on_off,
- &reason, 1, 1);
+ if (!cpu_isset(*oncpu, cpu_online_map)) {
+ printk(KERN_ERR "tick-braodcast: ignoring broadcast for "
+ "offline CPU #%d\n", *oncpu);
+ } else {
+
+ if (cpu == *oncpu)
+ tick_do_broadcast_on_off(&reason);
+ else
+ smp_call_function_single(*oncpu,
+ tick_do_broadcast_on_off,
+ &reason, 1, 1);
+ }
put_cpu();
}
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH] Ignore bogus ACPI info for offline CPUs
2007-05-19 14:22 [PATCH] Ignore bogus ACPI info for offline CPUs Thomas Gleixner
@ 2007-05-21 16:47 ` Darren Hart
2007-05-21 17:08 ` [stable] " Chris Wright
0 siblings, 1 reply; 6+ messages in thread
From: Darren Hart @ 2007-05-21 16:47 UTC (permalink / raw)
To: Thomas Gleixner; +Cc: LKML, Len Brown, Ingo Molnar, Andrew Morton, Stable Team
On Saturday 19 May 2007 07:22:50 Thomas Gleixner wrote:
> Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
> hang, because ACPI ignores the maxcpus setting and sends timer broadcast
> info for the offline CPUs. This results in a stuck for ever call to
> smp_call_function_single() on an offline CPU.
>
> Ignore the bogus information and print a kernel error to remind ACPI
> folks to fix it.
>
> Affects 2.6.21 / 2.6.22-rc
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
When I first booted with this patch I received the following in a loop:
irq 9: nobody cared (try booting with the "irqpoll" option)
Call Trace:
[<ffffffff8106d5a4>] dump_trace+0xaa/0x32a
[<ffffffff8106d865>] show_trace+0x41/0x5c
[<ffffffff8106d895>] dump_stack+0x15/0x17
[<ffffffff810c50b8>] __report_bad_irq+0x38/0x87
[<ffffffff810c52cb>] note_interrupt+0x1c4/0x1fc
[<ffffffff810c458d>] thread_simple_irq+0x6c/0x7e
[<ffffffff810c4dc3>] do_irqd+0x14a/0x3e4
[<ffffffff81033d3a>] kthread+0xf5/0x128
[<ffffffff8105ff68>] child_rip+0xa/0x12
handlers:
[<ffffffff8117736e>] (acpi_irq+0x0/0x1b)
I then tried to boot with maxcpus=1 and acpi=noirq and I got all the way to a
login prompt. As we have seen this "nobody cared" and child_rip dump issues
before - I think these are independent issues that should be tracked
separately.
Thanks,
Darren
>
> Index: linux-2.6.22-rc/kernel/time/tick-broadcast.c
> ===================================================================
> --- linux-2.6.22-rc.orig/kernel/time/tick-broadcast.c
> +++ linux-2.6.22-rc/kernel/time/tick-broadcast.c
> @@ -244,11 +244,18 @@ void tick_broadcast_on_off(unsigned long
> {
> int cpu = get_cpu();
>
> - if (cpu == *oncpu)
> - tick_do_broadcast_on_off(&reason);
> - else
> - smp_call_function_single(*oncpu, tick_do_broadcast_on_off,
> - &reason, 1, 1);
> + if (!cpu_isset(*oncpu, cpu_online_map)) {
> + printk(KERN_ERR "tick-braodcast: ignoring broadcast for "
> + "offline CPU #%d\n", *oncpu);
> + } else {
> +
> + if (cpu == *oncpu)
> + tick_do_broadcast_on_off(&reason);
> + else
> + smp_call_function_single(*oncpu,
> + tick_do_broadcast_on_off,
> + &reason, 1, 1);
> + }
> put_cpu();
> }
--
Darren Hart
IBM Linux Technology Center
Realtime Linux Team
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [stable] [PATCH] Ignore bogus ACPI info for offline CPUs
2007-05-21 16:47 ` Darren Hart
@ 2007-05-21 17:08 ` Chris Wright
2007-05-21 17:32 ` Thomas Gleixner
2007-05-21 17:58 ` Darren Hart
0 siblings, 2 replies; 6+ messages in thread
From: Chris Wright @ 2007-05-21 17:08 UTC (permalink / raw)
To: Darren Hart
Cc: Thomas Gleixner, Andrew Morton, Stable Team, Ingo Molnar, LKML,
Len Brown
* Darren Hart (dvhltc@us.ibm.com) wrote:
> On Saturday 19 May 2007 07:22:50 Thomas Gleixner wrote:
> > Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
> > hang, because ACPI ignores the maxcpus setting and sends timer broadcast
> > info for the offline CPUs. This results in a stuck for ever call to
> > smp_call_function_single() on an offline CPU.
> >
> > Ignore the bogus information and print a kernel error to remind ACPI
> > folks to fix it.
> >
> > Affects 2.6.21 / 2.6.22-rc
> >
> > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
>
> When I first booted with this patch I received the following in a loop:
>
> irq 9: nobody cared (try booting with the "irqpoll" option)
What happens when booting w/out this patch? Don't want to add known
regression to -stable.
thanks,
-chris
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [stable] [PATCH] Ignore bogus ACPI info for offline CPUs
2007-05-21 17:08 ` [stable] " Chris Wright
@ 2007-05-21 17:32 ` Thomas Gleixner
2007-05-21 17:57 ` Chris Wright
2007-05-21 17:58 ` Darren Hart
1 sibling, 1 reply; 6+ messages in thread
From: Thomas Gleixner @ 2007-05-21 17:32 UTC (permalink / raw)
To: Chris Wright
Cc: Darren Hart, Andrew Morton, Stable Team, Ingo Molnar, LKML,
Len Brown
On Mon, 2007-05-21 at 10:08 -0700, Chris Wright wrote:
> * Darren Hart (dvhltc@us.ibm.com) wrote:
> > On Saturday 19 May 2007 07:22:50 Thomas Gleixner wrote:
> > > Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
> > > hang, because ACPI ignores the maxcpus setting and sends timer broadcast
> > > info for the offline CPUs. This results in a stuck for ever call to
> > > smp_call_function_single() on an offline CPU.
> > >
> > > Ignore the bogus information and print a kernel error to remind ACPI
> > > folks to fix it.
> > >
> > > Affects 2.6.21 / 2.6.22-rc
> > >
> > > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> >
> > When I first booted with this patch I received the following in a loop:
> >
> > irq 9: nobody cared (try booting with the "irqpoll" option)
>
> What happens when booting w/out this patch? Don't want to add known
> regression to -stable.
See commit log:
Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
hang, because ACPI ignores the maxcpus setting and sends timer broadcast
info for the offline CPUs. This results in a stuck for ever call to
smp_call_function_single() on an offline CPU.
The irq 9 issue is a separate problem and only surfaces on some boxen,
but it's not related to this patch. It's related to maxcpus=1 as well.
tglx
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [stable] [PATCH] Ignore bogus ACPI info for offline CPUs
2007-05-21 17:32 ` Thomas Gleixner
@ 2007-05-21 17:57 ` Chris Wright
0 siblings, 0 replies; 6+ messages in thread
From: Chris Wright @ 2007-05-21 17:57 UTC (permalink / raw)
To: Thomas Gleixner
Cc: Chris Wright, Darren Hart, Andrew Morton, Stable Team,
Ingo Molnar, LKML, Len Brown
* Thomas Gleixner (tglx@linutronix.de) wrote:
> The irq 9 issue is a separate problem and only surfaces on some boxen,
> but it's not related to this patch. It's related to maxcpus=1 as well.
Thanks for confirming, just was double checking the two issues were
indeed separate.
thanks,
-chris
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [stable] [PATCH] Ignore bogus ACPI info for offline CPUs
2007-05-21 17:08 ` [stable] " Chris Wright
2007-05-21 17:32 ` Thomas Gleixner
@ 2007-05-21 17:58 ` Darren Hart
1 sibling, 0 replies; 6+ messages in thread
From: Darren Hart @ 2007-05-21 17:58 UTC (permalink / raw)
To: Chris Wright
Cc: Thomas Gleixner, Andrew Morton, Stable Team, Ingo Molnar, LKML,
Len Brown
On Monday 21 May 2007 10:08:15 Chris Wright wrote:
> * Darren Hart (dvhltc@us.ibm.com) wrote:
> > On Saturday 19 May 2007 07:22:50 Thomas Gleixner wrote:
> > > Booting a SMP kernel with maxcpus=1 on a SMP system leads to a hard
> > > hang, because ACPI ignores the maxcpus setting and sends timer
> > > broadcast info for the offline CPUs. This results in a stuck for ever
> > > call to smp_call_function_single() on an offline CPU.
> > >
> > > Ignore the bogus information and print a kernel error to remind ACPI
> > > folks to fix it.
> > >
> > > Affects 2.6.21 / 2.6.22-rc
> > >
> > > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> >
> > When I first booted with this patch I received the following in a loop:
> >
> > irq 9: nobody cared (try booting with the "irqpoll" option)
>
> What happens when booting w/out this patch? Don't want to add known
> regression to -stable.
The system will boot w/o acpi=noirq with and without this patch if maxcpus is
not specified. If maxcpus is specified without the patch, the system locks
up as Thomas described. If maxcpus is specified with the patch, then
acpi=noirq is required to boot - but it will boot. This does not introduce a
regression IMO.
--Darren
>
> thanks,
> -chris
--
Darren Hart
IBM Linux Technology Center
Realtime Linux Team
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2007-05-21 18:00 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-19 14:22 [PATCH] Ignore bogus ACPI info for offline CPUs Thomas Gleixner
2007-05-21 16:47 ` Darren Hart
2007-05-21 17:08 ` [stable] " Chris Wright
2007-05-21 17:32 ` Thomas Gleixner
2007-05-21 17:57 ` Chris Wright
2007-05-21 17:58 ` Darren Hart
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox