summaryrefslogtreecommitdiff
path: root/scripts/vyatta-auto-irqaffin.pl
AgeCommit message (Collapse)Author
2009-10-12Bugfix 2593: Introduce automatic static IRQ affinity balancing for some NICs.Bob Gilligan
This change implements a mechanism for setting the IRQ affinity of NIC interrupts in a way that is optimally balanced. The affinity settings are static, and are set up at configuration time. I've added "auto" as a new legal value to the "interfaces ethernet ethX smp_affinity" configuration parameter. If this value is set, then the system attempts to perform automatic IRQ affinity assignment. At this time, automatic IRQ affinity is supported only for multiqueue NICs that use the igb or bnx2 drivers. Even with these two, differences in the organization of queues and their naming convention necessitate some NIC-specific code. The assignment strategy attempts to assign all queues of all NICs that share the same queue number to the same CPU. This has been shown to be optimal for IP forwarding workloads in 2.6.31 kernels. Setting the value to "auto" for NICs that use other drivers will be a no-op.