#!/usr/bin/env sh
if [ "$1" == "start" ]; then
  echo 0 > /sys/devices/system/cpu/intel_pstate/no_turbo
  tee /sys/devices/system/cpu/cpufreq/policy*/scaling_governor <<< performance
  exit
elif [ "$1" == "stop" ]; then
  tee /sys/devices/system/cpu/cpufreq/policy*/scaling_governor <<< powersave
  exit
fi
