Jetson TK1 - Changing the clocks while running

Hi,
I would like to “manually” change the cpu/gpu/mem clocks of the Jetson TK1 from a running program, in order to tune energy consumption accordingly to the program needs; is there any documentation about the best way to do that? Or is here someone who already did it?
In particular I am concerned about the time needed to change the clocks, e.g. if I write in /sys/devices/system/… or /sys/kernel/debug/clock/… the desired clocks (as suggested in http://elinux.org/Jetson/Performance), how much time is needed to actually change them?

Best Regards,

Enrico

There’s some info here:

https://www.kernel.org/doc/Documentation/cpu-freq/governors.txt

On my AMD desktop CPU:

$ cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_transition_latency
4000

I can’t now check what that is on Jetson and I’m not exactly sure if the values there helps answering your question. I would guess that you can change it at least tens of times per second.

EDIT: About actually changing the values. One way is to use cpufreq-set (from cpufrequtils package) but I don’t think that can set cores off-line or on-line so you may be better off just setting them manually by writing to those sysfs files.