diff options
author | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2010-11-12 10:41:31 -0800 |
---|---|---|
committer | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2010-11-12 11:07:09 -0800 |
commit | ac9042acae2579b03d39fa6d5b7a8dbef1a8a048 (patch) | |
tree | d71efb8490456c3b1ec74c6e9cac3e517633e024 /templates/interfaces | |
parent | 500c844e27d7ff989ae73a8cff506552844cdf70 (diff) | |
download | vyatta-cfg-system-ac9042acae2579b03d39fa6d5b7a8dbef1a8a048.tar.gz vyatta-cfg-system-ac9042acae2579b03d39fa6d5b7a8dbef1a8a048.zip |
New IRQ affinity script and RPS support
Replace old script with new cleaner script that handles both
IRQ affinity and Receive Packet Steering. Instead of two scripts
(one for mask and one for auto), do it all with one script.
Receive Packet Steering is supported in two ways.
If 'auto' is used, then both threads on HT system will be
used for receive processing.
If explicit mask is given, then two masks can be used to set
both IRQ cpus and RPS cpus.
Diffstat (limited to 'templates/interfaces')
-rw-r--r-- | templates/interfaces/ethernet/node.tag/smp_affinity/node.def | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/templates/interfaces/ethernet/node.tag/smp_affinity/node.def b/templates/interfaces/ethernet/node.tag/smp_affinity/node.def index 671a28f0..1f8a2610 100644 --- a/templates/interfaces/ethernet/node.tag/smp_affinity/node.def +++ b/templates/interfaces/ethernet/node.tag/smp_affinity/node.def @@ -15,24 +15,14 @@ type: txt help: CPU interrupt affinity mask -val_help: <hex>; Bitmask representing CPUs that this NIC will interrupt val_help: auto; Automatic CPU affinity (default) +val_help: <hex>; Bitmask representing CPUs that this NIC will interrupt +val_help: <hex>,<hex>; Bitmasks representing CPUs for interrupt and receive processing default: "auto" -syntax:expression: $VAR(@) == "auto" || pattern $VAR(@) "^[0-9a-f]+$" ; +syntax:expression: $VAR(@) == "auto" || pattern $VAR(@) "^[0-9a-f]+(|,[0-9a-f]+)$" ; "IRQ affinity mask must be hex value or auto" -commit:expression: exec "\ - [ \"$VAR(@)\" == \"auto\" ] || \ - /opt/vyatta/sbin/vyatta-irqaffin check $VAR(../@) $VAR(@)" - -update: if [ "$VAR(@)" = "auto" ]; then - sudo /opt/vyatta/sbin/vyatta-auto-irqaffin.pl --setup $VAR(../@) - else - sudo /opt/vyatta/sbin/vyatta-irqaffin set $VAR(../@) $VAR(@) - fi - -delete: [ -d /sys/class/net/$VAR(../@) ] || exit 0 - sudo /opt/vyatta/sbin/vyatta-irqaffin reset $VAR(../@) +update: sudo /opt/vyatta/sbin/irq-affinity.pl $VAR(../@) $VAR(@) |