[Magisk] sklchan:
Just a suggestion, will you add in cpu frequencies decreasing for the battery saver mode in future?? Currently I'm altering the 6.0 b5 to reduce my max cpu frequencies for the big cores as my note fe somehow seem got unknown hw issues which will random reboot when not tuned down it's CPU... :crying:

The charges:

# CPU POWER =========================================#

CPU=/sys/devices/system/cpu
GOV=$(cat $NFS/governor.txt);

if [ -d $CPU/cpu9 ]; then
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu8/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu9/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu8/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu9/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu8/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu9/cpufreq/scaling_governor

CORES=Deca-Core
core=10
ML=/sys/devices/system/cpu/cpu0/cpufreq/$GOV
MB=/sys/devices/system/cpu/cpu5/cpufreq/$GOV
if [ -e /sys/devices/system/cpu/cpufreq/$GOV ]; then
ML=/sys/devices/system/cpu/cpufreq/$GOV
fi;
elif [ -d $CPU/cpu7 ]; then
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu3/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu4/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu5/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu6/cpufreq/scaling_max_freq
chmod 0666 /sys/devices/system/cpu/cpu7/cpufreq/scaling_max_freq
echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
echo "1482000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo "1482000" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
echo "1482000" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
echo "1482000" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_max_freq
echo "1248000" > /sys/devices/system/cpu/cpu4/cpufreq/scaling_max_freq
echo "1248000" > /sys/devices/system/cpu/cpu5/cpufreq/scaling_max_freq
echo "1248000" > /sys/devices/system/cpu/cpu6/cpufreq/scaling_max_freq
echo "1248000" > /sys/devices/system/cpu/cpu7/cpufreq/scaling_max_freq
chmod 0444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu3/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu4/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu5/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu6/cpufreq/scaling_max_freq
chmod 0664 /sys/devices/system/cpu/cpu7/cpufreq/scaling_max_freq

CORES=Octa-Core
core=8
ML=/sys/devices/system/cpu/cpu0/cpufreq/$GOV
MB=/sys/devices/system/cpu/cpu4/cpufreq/$GOV
if [ -e /sys/devices/system/cpu/cpufreq/$GOV ]; then
ML=/sys/devices/system/cpu/cpufreq/$GOV
fi;
elif [ -d $CPU/cpu5 ]; then
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor

CORES=Hexa-Core
core=6
ML=/sys/devices/system/cpu/cpu0/cpufreq/$GOV
MB=/sys/devices/system/cpu/cpu3/cpufreq/$GOV
if [ -e /sys/devices/system/cpu/cpufreq/$GOV ]; then
ML=/sys/devices/system/cpu/cpufreq/$GOV
fi;
elif [ -d $CPU/cpu3 ]; then
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor

CORES=Quad-Core
core=4
ML=/sys/devices/system/cpu/cpu0/cpufreq/$GOV
MB=/sys/devices/system/cpu/cpu2/cpufreq/$GOV
if [ -e /sys/devices/system/cpu/cpufreq/$GOV ]; then
ML=/sys/devices/system/cpu/cpufreq/$GOV
fi;
elif [ -d $CPU/cpu1 ]; then
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0666 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 0444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor

CORES=Dual-Core
core=2
ML=/sys/devices/system/cpu/cpu0/cpufreq/$GOV
MB=/sys/devices/system/cpu/cpu1/cpufreq/$GOV
if [ -e /sys/devices/system/cpu/cpufreq/$GOV ]; then
ML=/sys/devices/system/cpu/cpufreq/$GOV
fi;
fi;

CPUBATTERY() {
if [ "$GOV" == "smurfutil_flex" ]; then
echo "1" > $ML/pl 2>/dev/null
echo "9" > $ML/bit_shift1 2>/dev/null
echo "6" > $ML/bit_shift1_2 2>/dev/null
echo "6" > $ML/bit_shift2 2>/dev/null
echo "45" > $ML/target_load1 2>/dev/null
echo "75" > $ML/target_load2 2>/dev/null
echo "1" > $MB/pl 2>/dev/null
echo "9" > $MB/bit_shift1 2>/dev/null
echo "6" > $MB/bit_shift1_2 2>/dev/null
echo "6" > $MB/bit_shift2 2>/dev/null
echo "45" > $MB/target_load1 2>/dev/null
echo "75" > $MB/target_load2 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "pixutil" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "pwrutilx" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "pixel_schedutil" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "helix_schedutil" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "schedutil" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "blu_schedutil" ]; then
echo "1000" > $MB/up_rate_limit_us 2>/dev/null
echo "1000" > $MB/down_rate_limit_us 2>/dev/null
echo "1000" > $ML/up_rate_limit_us 2>/dev/null
echo "1000" > $ML/down_rate_limit_us 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "blu_active" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "darkness" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "elementalx" ]; then
echo "5" > $MB/down_differential 2>/dev/null
echo "0" > $MB/gboost 2>/dev/null
echo "0" > $MB/input_event_timeout 2>/dev/null
echo "40000" > $MB/sampling_rate 2>/dev/null
echo "30000" > $MB/ui_sampling_rate 2>/dev/null
echo "99" > $MB/up_threshold 2>/dev/null
echo "99" > $MB/up_threshold_any_cpu_load 2>/dev/null
echo "99" > $MB/up_threshold_multi_core 2>/dev/null
echo "5" > $ML/down_differential 2>/dev/null
echo "0" > $ML/gboost 2>/dev/null
echo "0" > $ML/input_event_timeout 2>/dev/null
echo "40000" > $ML/sampling_rate 2>/dev/null
echo "30000" > $ML/ui_sampling_rate 2>/dev/null
echo "99" > $ML/up_threshold 2>/dev/null
echo "99" > $ML/up_threshold_any_cpu_load 2>/dev/null
echo "99" > $ML/up_threshold_multi_core 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "zzmoove" ]; then
echo "85" > $MB/up_threshold 2>/dev/null
echo "75" > $MB/smooth_up 2>/dev/null
echo "0" > $MB/scaling_proportional 2>/dev/null
echo "70000" $MB/sampling_rate_min 2>/dev/null
echo "70000" $MB/sampling_rate 2>/dev/null
echo "1" > $MB/sampling_down_factor 2>/dev/null
echo "0" > $MB/ignore_nice_load 2>/dev/null
echo "0" > $MB/fast_scaling_up 2>/dev/null
echo "0" > $MB/fast_scaling_down 2>/dev/null
echo "50" > $MB/down_threshold 2>/dev/null
echo "85" > $ML/up_threshold 2>/dev/null
echo "75" > $ML/smooth_up 2>/dev/null
echo "0" > $ML/scaling_proportional 2>/dev/null
echo "70000" $ML/sampling_rate_min 2>/dev/null
echo "70000" $ML/sampling_rate 2>/dev/null
echo "1" > $ML/sampling_down_factor 2>/dev/null
echo "0" > $ML/ignore_nice_load 2>/dev/null
echo "0" > $ML/fast_scaling_up 2>/dev/null
echo "0" > $ML/fast_scaling_down 2>/dev/null
echo "50" > $ML/down_threshold 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "interactiveplus" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "interactive_pro" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "interactivepro" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "interactive" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "interactivex" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "phantom" ]; then
echo "0" > $ML/boost 2>/dev/null
echo "0" > $ML/boostpulse 2>/dev/null
echo "0" > $ML/boostpulse_duration 2>/dev/null
echo "1" > $ML/fastlane 2>/dev/null
echo "0" > $ML/align_windows 2>/dev/null
echo "1" > $ML/use_migration_notif 2>/dev/null
echo "1" > $ML/use_sched_load 2>/dev/null
echo "0" > $ML/enable_prediction 2>/dev/null
echo "1" > $ML/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "20000" > $ML/timer_rate 2>/dev/null
echo "0" > $ML/io_is_busy 2>/dev/null
echo "19000" > $ML/min_sample_time 2>/dev/null
echo "80000" > $ML/timer_slack 2>/dev/null
#############################################
echo "0" > $MB/boost 2>/dev/null
echo "0" > $MB/boostpulse 2>/dev/null
echo "0" > $MB/boostpulse_duration 2>/dev/null
echo "1" > $MB/fastlane 2>/dev/null
echo "0" > $MB/align_windows 2>/dev/null
echo "1" > $MB/use_migration_notif 2>/dev/null
echo "1" > $MB/use_sched_load 2>/dev/null
echo "0" > $MB/enable_prediction 2>/dev/null
echo "1" > $MB/fast_ramp_down 2>/dev/null
echo "85" > $ML/go_hispeed_load 2>/dev/null
echo "12000" > $MB/timer_rate 2>/dev/null
echo "0" > $MB/io_is_busy 2>/dev/null
echo "60000" > $MB/min_sample_time 2>/dev/null
echo "80000" > $MB/timer_slack 2>/dev/null
TUNE=Tuned
elif [ "$GOV" == "ondemand" ]; then
echo "90" > $MB/up_threshold 2>/dev/null
echo "85" > $MB/up_threshold_any_cpu_load 2>/dev/null
echo "85" > $MB/up_threshold_multi_core 2>/dev/null
echo "75000" > $MB/sampling_rate 2>/dev/null
echo "2" > $MB/sampling_down_factor 2>/dev/null
echo "10" > $MB/down_differential 2>/dev/null
echo "35" > $MB/freq_step 2>/dev/null
echo "90" > $ML/up_threshold 2>/dev/null
echo "85" > $ML/up_threshold_any_cpu_load 2>/dev/null
echo "85" > $ML/up_threshold_multi_core 2>/dev/null
echo "75000" > $ML/sampling_rate 2>/dev/null
echo "2" > $ML/sampling_down_factor 2>/dev/null
echo "10" > $ML/down_differential 2>/dev/null
echo "35" > $ML/freq_step 2>/dev/null
TUNE=Tuned
else
TUNE=Not_Tuned
fi;

chmod 0444 $ML
chmod 0444 $MB
echo "* CPU Frequencies = Decreased *" | tee -a $LOG;
echo "* CPU Power $CORES $GOV = $TUNE *" | tee -a $LOG;
}