public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: set nr_irqs_gsi only in probe_nr_irqs_gsi
@ 2010-02-24  8:17 Yinghai Lu
  2010-02-24  8:19 ` [PATCH] x86: kill smpboot_hooks.h Yinghai Lu
  2010-02-26  0:09 ` [PATCH -v2] x86: set nr_irqs_gsi only in probe_nr_irqs_gsi Yinghai Lu
  0 siblings, 2 replies; 3+ messages in thread
From: Yinghai Lu @ 2010-02-24  8:17 UTC (permalink / raw)
  To: H. Peter Anvin, Ingo Molnar, Thomas Gleixner
  Cc: Pan, Jacob jun, linux-kernel@vger.kernel.org


don't clear that in arch_early_irq_init

probe_nr_irqs_gsi is always called when ioapic is selected in config.

so even for mrst, print out from probe_nr_irqs_gsi report correct
nr_irqs_gsi

Signed-off-by: Yinghai Lu <yinghai@kernel.org>

---
 arch/x86/kernel/apic/io_apic.c |   10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

Index: linux-2.6/arch/x86/kernel/apic/io_apic.c
===================================================================
--- linux-2.6.orig/arch/x86/kernel/apic/io_apic.c
+++ linux-2.6/arch/x86/kernel/apic/io_apic.c
@@ -151,10 +151,12 @@ int __init arch_early_irq_init(void)
 	int node;
 	int i;
 
-	if (!legacy_pic->nr_legacy_irqs) {
-		nr_irqs_gsi = 0;
+	/*
+	 * in case, io apic is not detected
+	 * then setup_IO_APIC() is not called
+	 */
+	if (!legacy_pic->nr_legacy_irqs)
 		io_apic_irqs = ~0UL;
-	}
 
 	cfg = irq_cfgx;
 	count = ARRAY_SIZE(irq_cfgx);
@@ -3857,6 +3859,8 @@ void __init probe_nr_irqs_gsi(void)
 {
 	int nr = 0;
 
+	nr_irqs_gsi = legacy_pic->nr_legacy_irqs;
+
 	nr = acpi_probe_gsi();
 	if (nr > nr_irqs_gsi) {
 		nr_irqs_gsi = nr;

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-02-26  0:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-24  8:17 [PATCH] x86: set nr_irqs_gsi only in probe_nr_irqs_gsi Yinghai Lu
2010-02-24  8:19 ` [PATCH] x86: kill smpboot_hooks.h Yinghai Lu
2010-02-26  0:09 ` [PATCH -v2] x86: set nr_irqs_gsi only in probe_nr_irqs_gsi Yinghai Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox