- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am following directions on this page (https://docs.nxp.com/bundle/GUID-39A0A446-70E5-4ED7-A580-E7508B61A5F1/page/GUID-40BE9AD5-DF6B-4D99-A...) about switching CPU frequency by writing to a file in /sys.
When I try to run the command
echo 799999 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed
I see the following error:
-bash: echo: write error: Invalid argument
What am I doing wrong? I tried other values like 300000, and I also tried putting the value in quotes, using the -n flag for echo, etc. I used chmod to add write permission to scaling_setspeed. Is there something else I need to do?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the default LSDK2108.
root@localhost:~# cd /sys/devices/system/cpu/cpu0/cpufreq
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# ls
affected_cpus cpuinfo_max_freq cpuinfo_transition_latency scaling_available_frequencies scaling_cur_freq scaling_governor scaling_min_freq stats
cpuinfo_cur_freq cpuinfo_min_freq related_cpus scaling_available_governors scaling_driver scaling_max_freq scaling_setspeed
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_available_governors
ondemand userspace performance
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# echo userspace > scaling_governor
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_cur_freq
600000
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_available_frequencies
1500000 1200000 750000 600000 375000 300000
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# echo 750000 > scaling_setspeed
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_cur_freq
750000

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the default LSDK2108.
root@localhost:~# cd /sys/devices/system/cpu/cpu0/cpufreq
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# ls
affected_cpus cpuinfo_max_freq cpuinfo_transition_latency scaling_available_frequencies scaling_cur_freq scaling_governor scaling_min_freq stats
cpuinfo_cur_freq cpuinfo_min_freq related_cpus scaling_available_governors scaling_driver scaling_max_freq scaling_setspeed
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_available_governors
ondemand userspace performance
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# echo userspace > scaling_governor
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_cur_freq
600000
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_available_frequencies
1500000 1200000 750000 600000 375000 300000
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# echo 750000 > scaling_setspeed
root@localhost:/sys/devices/system/cpu/cpu0/cpufreq# cat scaling_cur_freq
750000

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Please kindly share the MPU part number and SW version, thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@June_Lu This is the LS1028ARDB running LSDK 21.08, kernel 5.10.35.
