1 |
On 04/20/2015 09:05 PM, Walter Dnes wrote: |
2 |
> |
3 |
> Another item I'm missing is wildcarding directories in bash. The |
4 |
> selected values are applied to the CPUs in a loop that goes like so... |
5 |
> |
6 |
> for core in /sys/devices/system/cpu/cpu[0-9]/ |
7 |
> do |
8 |
> echo "${governor[${choiceminus}]}" > ${core}cpufreq/scaling_governor |
9 |
> echo -n "CPU ${core:27:1} set to " |
10 |
> cat ${core}cpufreq/scaling_governor |
11 |
> done |
12 |
|
13 |
for core in `ls /sys/devices/system/cpu/ | egrep "cpu[0-9]+"` |
14 |
|
15 |
This works great on my desktop with 12 cores. |
16 |
|
17 |
Alec |