I asked a related question earlier, but I wasn't very clear. In a system with two CPUs or a Dual-core CPU, how to redirect the interrupts from a particular device based on PCI bus/dev number to specific CPUs or cores?
Thanks a lot.
IRQ redirection based on BusNo/DevNo
- xenos
- Member
- Posts: 1121
- Joined: Thu Aug 11, 2005 11:00 pm
- Libera.chat IRC: xenos1984
- Location: Tartu, Estonia
- Contact:
Re: IRQ redirection based on BusNo/DevNo
The magic keyword here is IOAPIC. It is present in any SMP system and does exactly what you want - it routes IRQs from different sources to the CPU(s). You can configure this routing by setting the IRQ routing tables - have a look at the wiki for some more information and links that might help you.
Re: IRQ redirection based on BusNo/DevNo
Yes I was trying to program ioapic after getting their base addresses from the MP-table. But not sure how to do the redirection based on bus/dev numbers.
Re: IRQ redirection based on BusNo/DevNo
You get an IOAPIC input map from the MP or ACPI tables. Look up the device you want and you get the input number which you need to use when programming the APIC; you can't use the bus/dev/function values directly, IIRC.sawdust wrote:Yes I was trying to program ioapic after getting their base addresses from the MP-table. But not sure how to do the redirection based on bus/dev numbers.