op_cpuspeed: show current clock
[openpandora.oe.git] / recipes / pandora-system / pandora-scripts / op_cpuspeed.sh
index beb1b7e..16a9a2e 100755 (executable)
@@ -58,7 +58,7 @@ if [ $newmhz ]; then
         if [ $newmhz -le $minmhz ]; then newmhz=$minmhz; fi
         if [ $newmhz -ge $maxmhz ]; then newmhz=$maxmhz; fi
        echo $newmhz > $device
         if [ $newmhz -le $minmhz ]; then newmhz=$minmhz; fi
         if [ $newmhz -ge $maxmhz ]; then newmhz=$maxmhz; fi
        echo $newmhz > $device
-       echo cpu_mhz_max set to $(cat $device)
+       echo "cpu_mhz_max set to $(cat $device)"
 
        if [ -e /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ]; then
                # must poke cpufreq so it does the actual clock transition
 
        if [ -e /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ]; then
                # must poke cpufreq so it does the actual clock transition
@@ -68,5 +68,6 @@ if [ $newmhz ]; then
                if [ "$gov" = "userspace" ]; then
                        echo $[ $newmhz * 1000 ] > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed
                fi
                if [ "$gov" = "userspace" ]; then
                        echo $[ $newmhz * 1000 ] > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed
                fi
+               echo "current CPU clock is $(cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq)"
        fi
 fi
        fi
 fi