This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Function to set IRQ affinity | |
set_affinity() { | |
irq=$1 | |
cpu_mask=$2 | |
# Check if the CPU mask is valid | |
if echo "$cpu_mask" | grep -qE '^[0-9A-Fa-f]+$'; then | |
echo "$cpu_mask" > "/proc/irq/$irq/smp_affinity" 2>/dev/null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Function to set IRQ affinity | |
set_affinity() { | |
irq=$1 | |
cpu_mask=$2 | |
# Check if the CPU mask is valid | |
if echo "$cpu_mask" | grep -qE '^[0-9A-Fa-f]+$'; then | |
echo "$cpu_mask" > "/proc/irq/$irq/smp_affinity" 2>/dev/null |