[Epic 4G Android Development] elevans:
I believe this init.d script is the culprit: 3cpufreq_screenstate_scaling. The script seems to modify the several relevant settings. This is taken directly from MarcusantROMV3:

#!/system/bin/sh

#

# Created by Calkulin

# Epic 4G Touch v1.4

BATTERY_PROFILES_ON="1"

BATTERY_PROFILE_1="85"

MAX_CPU_SPEED_PROFILE_1="1200000"

GPU_SPEED_PROFILE_1="10 325"

BATTERY_PROFILE_2="35"

MAX_CPU_SPEED_PROFILE_2="800000"

GPU_SPEED_PROFILE_2="10 200"

MAX_CPU_SPEED="1000000"

MIN_CPU_SPEED="200000"

GPU_SPEED="10 275"

CONSERVATIVE_SAMPLING_RATE="35000"

CONSERVATIVE_UP_THRESHOLD="75"

CONSERVATIVE_DOWN_THRESHOLD="35"

CONSERVATIVE_FREQ_STEP="15"

LAZY_SAMPLING_RATE="50000"

LAZY_UP_THRESHOLD="75"

ONDEMAND_SAMPLING_RATE="50000"

ONDEMAND_UP_THRESHOLD="75"

SLEEP_GOVERNOR_ON="0"

SLEEP_GOVERNOR="powersave"

SLEEP_CPU_SPEED_ON="1"

SLEEP_MAX_CPU_SPEED="800000"

SLEEP_MIN_CPU_SPEED="200000"

SLEEP_GPU_SPEED="10 100"

BOOT_GOVERNOR=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor`

ANDROID_OC="/data/app/com.jrummy.droidx.overclock*.apk"

OC_WIDGET="/data/app/org.freecoder.widgets.overclock*.apk"

QUICKCLOCK="/data/app/com.jpapps.quickclockadvanced*.apk"

SETCPU="/data/app/com.mhuang.overclocking*.apk"

(while [ 1 ]

do

AWAKE=`cat /sys/power/wait_for_fb_wake`

if [ $AWAKE = "awake" ]; then

if [ -e $ANDROID_OC ]; then

echo "Android Overclock is installed, IGNORING Screen State Scaling script"

elif [ -e $OC_WIDGET ]; then

echo "Overclock Widget is installed, IGNORING Screen State Scaling script"

elif [ -e $QUICKCLOCK ]; then

echo "QuickClock Advanced Overclock is installed, IGNORING Screen State Scaling script"

elif [ -e $SETCPU ]; then

echo "SetCPU is installed, IGNORING Screen State Scaling script"

else

if [ $BATTERY_PROFILES_ON = "1" ]; then

BATTERY_LEVEL=`cat /sys/class/power_supply/battery/capacity`

if [ $BATTERY_LEVEL -le $BATTERY_PROFILE_2 ]; then

echo $MAX_CPU_SPEED_PROFILE_2 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo $GPU_SPEED_PROFILE_2 > /sys/devices/virtual/misc/gpu_clock_control/gpu_control

echo "Battery Profile 2 ENABLED"

echo "Set MAX CPU speed to $MAX_CPU_SPEED_PROFILE_2"

echo "Set GPU speed to $GPU_SPEED_PROFILE_2"

elif [ $BATTERY_LEVEL -ge $BATTERY_PROFILE_1 ]; then

echo $MAX_CPU_SPEED_PROFILE_1 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo $GPU_SPEED_PROFILE_1 > /sys/devices/virtual/misc/gpu_clock_control/gpu_control

echo "Battery Profile 1 ENABLED"

echo "Set MAX CPU speed to $MAX_CPU_SPEED_PROFILE_1"

echo "Set GPU speed to $GPU_SPEED_PROFILE_1"

else

echo $MAX_CPU_SPEED > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo $GPU_SPEED > /sys/devices/virtual/misc/gpu_clock_control/gpu_control

echo "Set MAX CPU speed to $MAX_CPU_SPEED"

echo "Set GPU speed to $GPU_SPEED"

fi

else

echo $MAX_CPU_SPEED > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo $GPU_SPEED > /sys/devices/virtual/misc/gpu_clock_control/gpu_control

echo "Set MAX CPU speed to $MAX_CPU_SPEED"

echo "Set GPU speed to $GPU_SPEED"

fi

echo $MIN_CPU_SPEED > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq

echo "Set MIN CPU speed to $MIN_CPU_SPEED"

if [ $BOOT_GOVERNOR = "conservative" ]; then

echo "conservative" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo $CONSERVATIVE_SAMPLING_RATE > /sys/devices/system/cpu/cpu0/cpufreq/conservative/sampling_rate

echo $CONSERVATIVE_UP_THRESHOLD > /sys/devices/system/cpu/cpu0/cpufreq/conservative/up_threshold

echo $CONSERVATIVE_DOWN_THRESHOLD > /sys/devices/system/cpu/cpu0/cpufreq/conservative/down_threshold

echo $CONSERVATIVE_FREQ_STEP > /sys/devices/system/cpu/cpu0/cpufreq/conservative/freq_step

echo "Conservative Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "interactive" ]; then

echo "interactive" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo "Interactive Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "lazy" ]; then

echo "lazy" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo $LAZY_SAMPLING_RATE > /sys/devices/system/cpu/cpu0/cpufreq/lazy/sampling_rate

echo $LAZY_UP_THRESHOLD > /sys/devices/system/cpu/cpu0/cpufreq/lazy/up_threshold

echo "Lazy Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "ondemand" ]; then

echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo $ONDEMAND_SAMPLING_RATE > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate

echo $ONDEMAND_UP_THRESHOLD > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold

echo "OnDemand Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "performance" ]; then

echo "performance" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo "Performance Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "powersave" ]; then

echo "powersave" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo "PowerSave Awake Tweak ENABLED"

elif [ $BOOT_GOVERNOR = "smartass" ]; then

echo "smartass" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo "SmartAss Awake Tweak ENABLED"

fi

fi

AWAKE=

fi

SLEEPING=`cat /sys/power/wait_for_fb_sleep`

if [ $SLEEPING = "sleeping" ]; then

if [ -e $ANDROID_OC ]; then

echo "Android Overclock is installed, IGNORING Screen State Scaling script"

elif [ -e $OC_WIDGET ]; then

echo "Overclock Widget is installed, IGNORING Screen State Scaling script"

elif [ -e $QUICKCLOCK ]; then

echo "QuickClock Advanced Overclock is installed, IGNORING Screen State Scaling script"

elif [ -e $SETCPU ]; then

echo "SetCPU is installed, IGNORING Screen State Scaling script"

else

if [ $SLEEP_CPU_SPEED_ON = "1" ]; then

echo $SLEEP_MAX_CPU_SPEED > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo $SLEEP_MIN_CPU_SPEED > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq

echo $SLEEP_GPU_SPEED > /sys/devices/virtual/misc/gpu_clock_control/gpu_control

echo "Set MAX/MIN CPU speed to $SLEEP_MAX_CPU_SPEED/$SLEEP_MIN_CPU_SPEED"

echo "Set GPU speed to $SLEEP_GPU_SPEED"

fi

if [ $SLEEP_GOVERNOR_ON = "1" ]; then

if [ $BOOT_GOVERNOR = $SLEEP_GOVERNOR ]; then

echo "$SLEEP_GOVERNOR governor already ENABLED"

else

sleep 1

echo $SLEEP_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

GOVERNOR=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor`

if [ $GOVERNOR = $SLEEP_GOVERNOR ]; then

echo "$SLEEP_GOVERNOR Sleep Tweak ENABLED"

else

echo "$SLEEP_GOVERNOR governor could NOT be ENABLED"

fi

fi

fi

fi

SLEEPING=

fi

done &)