aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xprepare-device.sh35
1 files changed, 35 insertions, 0 deletions
diff --git a/prepare-device.sh b/prepare-device.sh
index 6f0b4fc..abb30b7 100755
--- a/prepare-device.sh
+++ b/prepare-device.sh
@@ -31,4 +31,39 @@ then
adb -s $IPADDR:5555 shell "cat /sys/kernel/bL_switcher/active"
fi
+if [ $1 == 'a7only' ]
+then
+ # disable IKS
+ IPADDR=`cat IPADDR`
+ echo "Disable IKS for $IPADDR"
+ adb connect $IPADDR:5555
+ adb devices
+ echo "Waiting for device"
+ adb wait-for-device
+ echo "adb -s $IPADDR:5555 shell \"echo 0 > /sys/kernel/bL_switcher/active\""
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/kernel/bL_switcher/active"
+ adb -s $IPADDR:5555 shell "cat /sys/kernel/bL_switcher/active"
+ echo "Disable A15 cluster"
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/devices/system/cpu/cpu3/online"
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/devices/system/cpu/cpu4/online"
+fi
+
+if [ $1 == 'a15only' ]
+then
+ # disable IKS
+ IPADDR=`cat IPADDR`
+ echo "Disable IKS for $IPADDR"
+ adb connect $IPADDR:5555
+ adb devices
+ echo "Waiting for device"
+ adb wait-for-device
+ echo "adb -s $IPADDR:5555 shell \"echo 0 > /sys/kernel/bL_switcher/active\""
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/kernel/bL_switcher/active"
+ adb -s $IPADDR:5555 shell "cat /sys/kernel/bL_switcher/active"
+ echo "Disable A7 cluster"
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/devices/system/cpu/cpu0/online"
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/devices/system/cpu/cpu1/online"
+ adb -s $IPADDR:5555 shell "echo 0 > /sys/devices/system/cpu/cpu2/online"
+fi
+
exit 0