The information provided by others is largely correct, but the solutions are not. The tricky bit will be finding the rogue interrupt, as it will vary depending the hardware you have, and may also change whenever you update your firmware/bios/etc. Assuming your running Linux, you can find it by running:
grep -Ev "^[ ]*0" /sys/firmware/acpi/interrupts/gpe?? | sort --field-separator=: --key=2 --numeric --reverse | head -1
The above snippet will look at all the interrupts, sort them numerically, and show you the one with the highest count. On my system the output looked like so:
/sys/firmware/acpi/interrupts/gpe69: 7802639 STS enabled unmasked
You can increase the number of interrupts shown by adjusting the value passed to the head
command, but given the CPU usage involved, it will almost always be the first line (after sorting), outside of a few very rare scenarios. Assuming you have identified the offending interrupt, you proceed to disable it like so:
echo disable > /sys/firmware/acpi/interrupts/gpe69
If you want to automate this process you can simply create a script with the following:
echo disable > $(grep -Ev '^[ ]*0' /sys/firmware/acpi/interrupts/gpe?? | sort --field-separator=: --key=2 --numeric --reverse | head -1 | awk -F: '{print $1}')
The above will version will require you to run it as root. To avoid that, you could use:
sudo sh -c "echo disable > $(grep -Ev '^[ ]*0' /sys/firmware/acpi/interrupts/gpe?? | sort --field-separator=: --key=2 --numeric --reverse | head -1 | awk -F: '{print $1}')"
Please note, that if the interrupt with the highest value has already been disabled, you will get an error. This can might happen if you run the snippet above more than once. If this happens, you will see an error that looks like the following:
sh: line 1: echo: write error: Invalid argument
It is easy to adjust the grep
expression to filter out interrupts that are already disabled. DO NOT DO THIS. if you do, then running the command above will could disable something important.
Finally, it might be wise to confirm this is your issue before disabling any of the interrupts. You can use the one liner below to confirm to the problem. It will print the counter value every second. If this is your problem you will see the value rise rapidly:
while true ; do grep -Ev '^[ ]*0' /sys/firmware/acpi/interrupts/gpe?? | sort --field-separator=: --key=2 --numeric --reverse | head -1 ; sleep 1 ; done
On my system this looked like so:
/sys/firmware/acpi/interrupts/gpe69: 7921836 STS enabled unmasked
/sys/firmware/acpi/interrupts/gpe69: 7925137 STS enabled unmasked
/sys/firmware/acpi/interrupts/gpe69: 7928459 EN STS enabled unmasked
/sys/firmware/acpi/interrupts/gpe69: 7931766 STS enabled unmasked
/sys/firmware/acpi/interrupts/gpe69: 7935122 STS enabled unmasked
my computer is very old (bought it in 2012) so I'm assuming it's just an incompatibility with the BIOS and the new version of Mint I'm using.
– Tica Sloth Jun 19 '20 at 22:57