pentoo-overlay/pentoo/pentoo-system/files/00-speed_shutdown.stop-r2
2016-09-01 00:21:11 -04:00

13 lines
494 B
Bash
Executable file

#!/bin/sh
for CPU in $(ls /sys/devices/system/cpu/|grep -E "cpu[0-9]+"); do
if [ -e /sys/devices/system/cpu/${CPU}/cpufreq/scaling_governor ]; then
echo performance > /sys/devices/system/cpu/${CPU}/cpufreq/scaling_governor
fi
done
for controller in $(ls /sys/class/scsi_host/|grep -E "host[0-9]+"); do
if [ -e /sys/class/scsi_host/${controller}/link_power_management_policy ]; then
echo max_performance > /sys/class/scsi_host/${controller}/link_power_management_policy
fi
done