Note: This stuff works on Ubuntu 12.04, Precise pangolin. It should be fairly easy to port to other distributions.
There has been a recent kernel bug that has, on certain systems like my wonderful, wonderful Lenovo y560p , lead to the massive uprising of interrupts, which can waste up to 60% of CPU time.
See what’s happening here? For the computer, it’s like when a random friendly sales team member randomly shows up at random times of thethe day to you, the random programmer, to say things like “sup man, hey yo IT pro what’s cookin man, hey, you must be doing some serious thinking and shit, but man, hey, just gotta check you out and ask what’s cookin’, man, so, hey, man, what’s cookin’?” and then look at you with big, brown eyes waiting for an intelligent answer.
This not only wastes aerial brownian motion, but can also suck up to 60% of your brain power (long term effects not counted). No wonder the poor, idle machine can’t get things done any more, because the CPU is clooged with the interrupt controller gone haywire incessantly screamin “SUP, MAN! YEAH!” It’s like Guantanamo for geeks. It’s not torture, bit it is enhanced communication.
The most obvious solution is to fire the sales team.
# Find GRUB_CMDLINE_LINUX_DEFAULT and add acpi=off to the end, like so:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi=off"
# Good riddance
This works like a charm. The sales team is gone, the chatter stops, and the CPU is free to work again (not to mention the tremendous emotional satisfaction).
However, it has a big minus. I have found that the sales team, properly kept outside of the IT office (kind of like farmers put wire fence around trees in goat pens), actually gets things of its own done. More specifically, I realized my Indigo IOx Expresscard
was no longer working, which was the reason I bought my beloved Lenovo in the first place. I hate to admit it, but firing the sales team is actually kind of a bad idea. Uh… sup guys, wanna come back, like, uh, would you?
Luckily, a very smart fellow on the linux kernel bug forum found a better solution: Instead of firing the entire sales team, we only fire the team member that does the most interrupting. Sales can still be made, we can work, all is well. First we need to find the culprit:
# Find the chatterbox
# He has the file with the highest number
sudo crontab -e
# now add this line, save, quit
@reboot echo "disable" > /sys/firmware/acpi/interrupts/gpeXX
# Note: for some reason, adding the line to /etc/rc.local doesn't work
# Put this in a new file /etc/pm/sleep.d/30_disable_gpe (XX is the culprit found above)
case "$1" in
echo "disable" > /sys/firmware/acpi/interrupts/gpeXX 2>/dev/null
This simply clobbers the interrupt that is problematic, while the express card still works great.
Oh, and I’m kidding about the sales team. I love you guys.