Return-Path: From: Qiu Tingting Date: Thu, 15 Nov 2018 12:26:02 +0800 Message-ID: <1542255972-10772-5-git-send-email-qiutt@cn.fujitsu.com> In-Reply-To: <1542255972-10772-1-git-send-email-qiutt@cn.fujitsu.com> References: <1542255972-10772-1-git-send-email-qiutt@cn.fujitsu.com> MIME-Version: 1.0 Content-Type: text/plain Subject: [Fuego] [PATCH 05/15] ptsematest: fix no nproc cmd on board List-Id: Mailing list for the Fuego test framework List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: fuego@lists.linuxfoundation.org If there is no nproc cmd on board, can not get target_cpu_number. Get target_cpu_number from /proc/cpuinfo file. Signed-off-by: Qiu Tingting --- engine/tests/Benchmark.ptsematest/fuego_test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/tests/Benchmark.ptsematest/fuego_test.sh b/engine/tests/Benchmark.ptsematest/fuego_test.sh index fc1a385..5f3fb44 100755 --- a/engine/tests/Benchmark.ptsematest/fuego_test.sh +++ b/engine/tests/Benchmark.ptsematest/fuego_test.sh @@ -19,7 +19,7 @@ function test_run { # ptsematest does not support a option for printing a summary only on exit. # So, We get some lines at the end of the command's output. # The number for getting the lines depends on the cpu number of target machine. - target_cpu_number=$(cmd "nproc") + target_cpu_number=$(cmd "cat /proc/cpuinfo | grep processor | wc -l") getting_line_number=$(( $target_cpu_number + $target_cpu_number )) report "cd $BOARD_TESTDIR/fuego.$TESTDIR; ./ptsematest $BENCHMARK_PTSEMATEST_PARAMS | tail -$getting_line_number" } -- 2.7.4