From a936db1e3a4f0f79796089b3d706a4958ef950a7 Mon Sep 17 00:00:00 2001 From: Lisa Nguyen Date: Tue, 17 Nov 2015 23:56:31 -0800 Subject: android/scripts/pm-qa: Update pm-qa.sh script Remove unused variables. Also add check to kill all pids associated with the cpuidle_killer program used in the cpuidle subtests, so PM-QA results can be shown in LAVA. Change-Id: I8885651499ca09bb5b17e234865e95c77e4fe4f0 Signed-off-by: Lisa Nguyen --- android/scripts/pm-qa.sh | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) (limited to 'android') diff --git a/android/scripts/pm-qa.sh b/android/scripts/pm-qa.sh index ed96a87..4499d0a 100755 --- a/android/scripts/pm-qa.sh +++ b/android/scripts/pm-qa.sh @@ -7,20 +7,9 @@ test_func(){ exit fi - bin_dir="/data/bin" - - if [ ! -d $bin_dir ]; then - mkdir $bin_dir - fi - - cd ${bin_dir} - - export PATH=${bin_dir}:$PATH - cd "${scripts_dir}" pwd_dir=$PWD - echo $pwd tests_dirs="cpuidle cpufreq cpuhotplug cputopology thermal" for dir in $tests_dirs; do @@ -32,22 +21,30 @@ test_func(){ continue fi - echo `pwd` - /system/bin/sh $var if [ $? -ne 1 ]; then continue fi - for file in `find . -name "*.sh" | sort`; do + filelist=$(find . -name "*.sh" | sort) + for file in $filelist; do path=$file - echo $path /system/bin/sh $path done cd .. done + # Find instances of cpuidle_killer and kill + # all pids associated with it until a better + # solution comes up. + pids=$(pidof "cpuidle_killer") + + for pid in $pids; do + kill -9 $pid + done + echo "pm-qa=pass" } test_func +exit -- cgit v1.2.3