From e71038268a122472a6e7650e889df18a75cfcb68 Mon Sep 17 00:00:00 2001 From: Santosh Shukla Date: Tue, 19 Aug 2014 21:52:59 +0530 Subject: is-cpu-isolated.sh: exit early in case of non-stress app By default isolation script runs 'stress' tasks on isolated cores. This patch changes it to not run 'stress' if user wants not to use 'stress' but some other test. Change-Id: I21f0d085f075adde4666bc8e4cb8747426a7b1ff Signed-off-by: Santosh Shukla Acked-by: Viresh Kumar Not-Tested-by: Viresh Kumar --- common/scripts/is-cpu-isolated.sh | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'common') diff --git a/common/scripts/is-cpu-isolated.sh b/common/scripts/is-cpu-isolated.sh index 99ae303..3122c71 100755 --- a/common/scripts/is-cpu-isolated.sh +++ b/common/scripts/is-cpu-isolated.sh @@ -148,6 +148,11 @@ create_dplane_cpuset() { echo $1 > /dev/cpuset/dplane/cpu$1/$CPUSET_PREFIX"cpus" echo 0 > /dev/cpuset/dplane/cpu$1/$CPUSET_PREFIX"sched_load_balance" + # exit early in case of non-stress app + if [ "stress" != "$TASK" ]; then + return + fi + # Move shell to isolated CPU echo $$ > /dev/cpuset/dplane/cpu$1/tasks -- cgit v1.2.3