/usr/sbin/cpufreqnextgovernor is in gkrellm-cpufreq 0.6.4-4.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | #!/bin/bash
cpu="$1"
# determine actual governor
actual_gov=`cpufreq-info -c $cpu -p | sed 's/.*\ //'`
# determine available governors
avail_gov=`cpufreq-info -c $cpu -g`
avail_gov1=`echo $avail_gov | sed "s/.*$actual_gov//"`
avail_gov2=`echo $avail_gov | sed "s/$actual_gov.*//"`
avail_gov=`echo "$avail_gov1 $avail_gov2" | sed "s/^\ //"`
next_gov=`echo $avail_gov | sed "s/\ .*//"`
cpufreq-set -c $cpu -g $next_gov
|