Jetson TK1: Need help disabling LP mode, and info on tegra_cpuquiet

I’m looking for information on the variables in /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet on the TK1, they’re not doing what I think they should and I can’t find any documentation:

There are 7 variables in the directory: down_delay, enable, hotplug_timeout idle_bottom_freq, idle_top_req, no_lp, and up_delay. I’m trying to force the processor to never go into LP mode, so I set enable to 0 and no_lp to 1 using:

sudo echo 0 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/enable
sudo echo 1 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/no_lp

When I cat the directory I see they’re set:

for file in `ls`; do echo $file `cat $file`; done
down_delay 500
enable 0
hotplug_timeout 100
idle_bottom_freq 204000
idle_top_freq 1092000
no_lp 1
up_delay 70

but when I check the active cluster I’m still in LP mode:

smc@tegra-ubuntu:~$ sudo ./showProcs.sh
Online Cores : 0
Active Cluster: LP
CPU temp: 34000  GPU temp: 34000
Clock Frequencies:
cpu 0 :  564000
cpu 1 : offline
cpu 2 : offline
cpu 3 : offline

Can somebody help me figure out how to keep the system in “G” mode and not “LP”, and also explain the no_lp variable if it doesn’t disable LP mode?

By the way, my showProcs.sh script is:

smc@tegra-ubuntu:~$ cat showProcs.sh
echo "Online Cores :" `cat /sys/devices/system/cpu/online`
echo "Active Cluster:" `cat /sys/kernel/cluster/active`
echo "CPU temp:" `cat /sys/devices/virtual/thermal/thermal_zone0/temp` " GPU temp:" `cat /sys/devices/virtual/thermal/thermal_zone1/temp`
echo "Clock Frequencies:"
if [ -e /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq ];
then echo "cpu 0 : " `cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq`
else echo "cpu 0 : offline"
fi
if [ -e /sys/devices/system/cpu/cpu1/cpufreq/scaling_cur_freq ];
then echo "cpu 1 : " `cat /sys/devices/system/cpu/cpu1/cpufreq/scaling_cur_freq`
else echo "cpu 1 : offline"
fi
if [ -e /sys/devices/system/cpu/cpu2/cpufreq/scaling_cur_freq ];
then echo "cpu 2 : " `cat /sys/devices/system/cpu/cpu2/cpufreq/scaling_cur_freq`
else echo "cpu 2 : offline"
fi
if [ -e /sys/devices/system/cpu/cpu3/cpufreq/scaling_cur_freq ];
then echo "cpu 3 : " `cat /sys/devices/system/cpu/cpu3/cpufreq/scaling_cur_freq`
else echo "cpu 3 : offline"
fi

You can get a nice 1-second refresh of your processor status by creating showProcs.sh and then running:

watch -n 1 sudo ./showProcs.sh

Did you check this:

http://elinux.org/Jetson/Performance#Restricting_to_low-power_core_only

echo LP > /sys/kernel/cluster/active

That is the opposite of what I’m trying to do, but reversing those instructions seems to keep the system out of LP mode. Just doing “echo G> /sys/kernel/cluster/active” does not have the desired effect, but manually turning on all 4 processors and disabling cpuquiet seems to:

echo 0 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/enable
echo 1 > /sys/devices/system/cpu/cpu1/online
echo 1 > /sys/devices/system/cpu/cpu2/online
echo 1 > /sys/devices/system/cpu/cpu3/online
echo G > /sys/kernel/cluster/active

I’d still like to know what ‘no_lp’ is supposed to do in /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/

Hi,
For ‘no_lp’ knob you could refer to code@kernel/arch/arm/mach-tegra/cpuquiet.c

/*

  • no_lp can be used to set what cluster cpuquiet uses
    • no_lp = 1: only G cluster
    • no_lp = 0: dynamically choose between both clusters (cpufreq based)
    • no_lp = -1: only LP cluster
  • Settings will be enforced directly upon write to no_lp
    */

I just tested on my Jetson TK1 and it works as expected, system locks to G cluster.

#sudo echo 1 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/no_lp

then
#cat /sys/kernel/cluster/active
G