From: Grazvydas Ignotas Date: Thu, 15 Mar 2012 21:14:59 +0000 (+0200) Subject: op_cpuspeed.sh: update cpufreq after clock change X-Git-Tag: sz_beta3~13 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4e9ac6ec918ac26680addc98f9527c0a2240b37b;p=openpandora.oe.git op_cpuspeed.sh: update cpufreq after clock change 3.2 uses cpufreq to change clock, so need to "poke" it. --- diff --git a/recipes/pandora-system/pandora-scripts.bb b/recipes/pandora-system/pandora-scripts.bb index 4d6af05..c747f5b 100644 --- a/recipes/pandora-system/pandora-scripts.bb +++ b/recipes/pandora-system/pandora-scripts.bb @@ -6,7 +6,7 @@ COMPATIBLE_MACHINE = "omap3-pandora" DEPENDS = "zenity dbus" RDEPENDS = "zenity dbus" -PR = "r85" +PR = "r86" SRC_URI = " \ file://op_paths.sh \ diff --git a/recipes/pandora-system/pandora-scripts/op_cpuspeed.sh b/recipes/pandora-system/pandora-scripts/op_cpuspeed.sh index 508df2c..39855dc 100755 --- a/recipes/pandora-system/pandora-scripts/op_cpuspeed.sh +++ b/recipes/pandora-system/pandora-scripts/op_cpuspeed.sh @@ -46,4 +46,11 @@ if [ $newmhz ]; then if [ $newmhz -ge $maxmhz ]; then newmhz=$maxmhz; fi echo $newmhz > $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 + # according to new limits + gov=$(cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor) + echo $gov > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor + fi fi