rc.pandora-state: Forgot to chmod 777 /tmp/nocleanwarn
[openpandora.oe.git] / recipes / pandora-system / pandora-state / rc.pandora-state
index 637f0b1..ef7f6d2 100644 (file)
@@ -53,10 +53,11 @@ d_start() {
        if [ -f /etc/pandora/shutdown ]; then
              rm /etc/pandora/shutdown
              sync
-             echo $cpuspeed > /proc/pandora/cpu_mhz_max
+             /usr/pandora/scripts/op_cpuspeed.sh -n $cpuspeed
        else
              echo "No clean shutdown - will not set CPU speed"
-             touch /tmp/nocleanwarn
+             echo "Yes" > /tmp/nocleanwarn
+             chmod 777 /tmp/nocleanwarn
        fi
        sed -n '1p' /etc/pandora/conf/nubs.state > /proc/pandora/nub0/mode
        sed -n '2p' /etc/pandora/conf/nubs.state > /proc/pandora/nub0/mouse_sensitivity
@@ -71,9 +72,13 @@ d_start() {
        sed -n '11p' /etc/pandora/conf/nubs.state > /proc/pandora/nub1/scroll_rate
        sed -n '12p' /etc/pandora/conf/nubs.state > /proc/pandora/nub1/mbutton_threshold
        echo "Enabling ZRAM Swap"
-       modprobe zram
        mkswap /dev/zram0
        swapon -p 5 /dev/zram0
+
+       # set audio powerdown delay (ms)
+       if [ -e /sys/devices/platform/soc-audio/PCM1773/pmdown_time ]; then
+               echo 60000 > /sys/devices/platform/soc-audio/PCM1773/pmdown_time
+       fi
 }
 
 case "$1" in