1
2
3
blueline:/sys/devices/system/cpu/cpu0 # ls
core_ctl cpufreq cpuidle hotplug isolate of_node online power rq-stats sched_load_boost subsystem uevent
blueline:/sys/devices/system/cpu/cpu0

查看当前核心的频率

1
2
3
4
5
6
7
8
9
:/sys/devices/system/cpu/cpu0/cpufreq # ls
affected_cpus cpuinfo_transition_latency scaling_boost_frequencies scaling_max_freq stats
cpuinfo_cur_freq related_cpus scaling_cur_freq scaling_min_freq
cpuinfo_max_freq scaling_available_frequencies scaling_driver scaling_setspeed
cpuinfo_min_freq scaling_available_governors scaling_governor schedutil
blueline:/sys/devices/system/cpu/cpu0/cpufreq # cat cpu
cpuinfo_cur_freq cpuinfo_max_freq cpuinfo_min_freq cpuinfo_transition_latency
blueline:/sys/devices/system/cpu/cpu0/cpufreq # cat cpuinfo_cur_freq
576000

查看当前核心的调度策略:cat scaling_governor

1
2
3
4
5
6
7
8
9
10
11
12
blueline:/sys/devices/system/cpu/cpu0/cpufreq # ls
affected_cpus cpuinfo_transition_latency scaling_boost_frequencies scaling_max_freq stats
cpuinfo_cur_freq related_cpus scaling_cur_freq scaling_min_freq
cpuinfo_max_freq scaling_available_frequencies scaling_driver scaling_setspeed
cpuinfo_min_freq scaling_available_governors scaling_governor schedutil
blueline:/sys/devices/system/cpu/cpu0/cpufreq # cat scaling_available_governors\
# ondemand:按需给与 powersave:节能的 performance:性能的(最高频)
conservative ondemand userspace powersave performance schedutil
//
blueline:/sys/devices/system/cpu/cpu0/cpufreq # cat scaling_governor
schedutil
blueline:/sys/devices/system/cpu/cpu0/cpufreq #

查看当前核心所有可能的频率

1
2
blueline:/sys/devices/system/cpu/cpu0/cpufreq # cat scaling_available_frequencies
300000 403200 480000 576000 652800 748800 825600 902400 979200 1056000 1132800 1228800 1324800 1420800 1516800 1612800 1689600 1766400

设置锁频,我们所以设置频率为performance