LinuxQuestions.org

LinuxQuestions.org (http://www.linuxquestions.org/questions/index.php)
-   Linux - Hardware (http://www.linuxquestions.org/questions/forumdisplay.php?f=18)
-   -   IRQ affinity doesn't work (http://www.linuxquestions.org/questions/showthread.php?t=4175436431)

icoming 11-09-2012 11:20 AM

IRQ affinity doesn't work
 
Hello,

I have 5 SSDs connect to 1 LSI 9207-8e card. When MSI-X is enabled (by default), the LSI card registers 16 IRQs in the kernel. When I read data from SSDs, all interrupts from the SSDs go to the same IRQ, which makes one CPU too busy to handle all interrupts. I want to distribute interrupts from SSDs to cores evenly. One way I tried is to set smp_affinity, so interrupts with the same IRQ number will be distributed to cores evenly, which is basically IRQ-affinity's job. However, I tried that, for example, I set
echo f > /proc/irq/48/smp_affinity
so ideally, all interrupts of IRQ 48 should be distributed to first 4 cores. However, when I read data again, I still see interrupts sent to only the first core.
I tried a few ways and hope to make it work. e.g., I closed irqbalance, disabled hot-pluggable CPU feature in the kernel, disable or enable MSI-X of the LSI driver. None of them make IRQ affinity work.
Has anyone made IRQ affinity work? Could you show me how to make it work?

Thanks a lot!
Da

business_kid 11-10-2012 10:07 AM

Quote:

echo f > /proc/irq/48/smp_affinity
You might be onto something with this. But I have never played with irq_affinity and I have smp_affinity files in every /proc/irq/ subdir and a default_smp_affinity in /proc/irq/ itself. All have the digit three, and I have 2 cores. Are you sure about the 'f'?

icoming 11-13-2012 07:20 PM

Quote:

Originally Posted by business_kid (Post 4826531)
You might be onto something with this. But I have never played with irq_affinity and I have smp_affinity files in every /proc/irq/ subdir and a default_smp_affinity in /proc/irq/ itself. All have the digit three, and I have 2 cores. Are you sure about the 'f'?

The machine I use have 64 logical processors, so yes. I set it right.

What I found is that if I only specify one core for each IRQ, then it works as expected. The interrupts are sent to the cores I specified. When I disabled the feature of hot-pluggable CPU in the kernel, it seems MSI-X works: interrupts are delivered to the cores where requests are issued. So even IRQ affinity doesn't work properly, interrupts can still be distributed to multiple cores when accessing multiple SSDs, which is good enough for me.


All times are GMT -5. The time now is 08:15 PM.