emkay443

Ubuntu 13.04 (Kernel 3.8) CPU fan fix

Jul 10th, 2013
183
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.08 KB | None | 0 0
  1. #!/bin/sh
  2. # Fixes CPU fan running at 100% after waking up from suspend/hibernate
  3. # in Ubuntu 13.04 (or Linux kernel 3.8 in general)
  4. #
  5. # Save this as /etc/pm/sleep.d/99fixcpufan.sh
  6. # and mark it as executable (sudo chmod +x /etc/pm/sleep.d/99fixcpufan.sh)
  7.  
  8. case "$1" in
  9.         hibernate|suspend)
  10.                 ;;
  11.         thaw|resume)
  12.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device0/cur_state;
  13.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device1/cur_state;
  14.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device2/cur_state;
  15.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device3/cur_state;
  16.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device4/cur_state;
  17.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device5/cur_state;
  18.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device6/cur_state;
  19.                 echo -n 0 > /sys/devices/virtual/thermal/cooling_device7/cur_state;
  20.                 ;;
  21.         *)
  22.                 exit 0
  23.                 ;;
  24. esac
Advertisement
Add Comment
Please, Sign In to add comment