BUG? nosmp and pcibios_fixup_irqs()

From: Oleg Nesterov
Date: Sun Oct 10 2004 - 10:28:26 EST


Hello.

void smp_boot_cpus(unsigned int max_cpus)
{
if (!max_cpus) {
smpboot_clear_io_apic_irqs();
// sets io_apic_irqs = 0;
return;
}

setup_IO_APIC();
}

void pcibios_fixup_irqs(void)
{
while (dev = pci_find_device())
if (io_apic_assign_pci_irqs)
dev->irq = IO_APIC_get_PCI_irq_vector();
}

It seems to me that this dev->irq assignment is wrong in case
when setup_IO_APIC() was not called, and this is the case for
'nosmp' parameter.

With this change:
- if (io_apic_assign_pci_irqs)
+ if (io_apic_assign_pci_irqs && io_apic_irqs)

my netwok card works with nosmp, but i never looked in
arch/i386/pci/ before, so i am probably wrong.

Or nosmp does not make sense without noapic?

Oleg.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/