From: Xiangyu Chen Date: Thu, 19 Jan 2023 05:24:26 +0000 (+0800) Subject: numactl: skip test case when target platform doesn't have 2 CPU node X-Git-Tag: 2022-10.3-langdale~86 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=da48bc443fec5bbc1fce356c3d5fd551a38a0705;p=thirdparty%2Fopenembedded%2Fopenembedded-core.git numactl: skip test case when target platform doesn't have 2 CPU node when current test platform doesn't have 2 or more CPU node, the test case would report FAIL, according to numa test script and numademo code, when return code=77 should be skip test, so using SKIP instead of FAIL in test script. Signed-off-by: Xiangyu Chen Signed-off-by: Luca Ceresoli Signed-off-by: Richard Purdie (cherry picked from commit fd0a82400d419bce8605a9445db9b20b8ddc01a7) Signed-off-by: Steve Sakoman --- diff --git a/meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch b/meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch index 9812ecc8b3a..a7bc8d322ee 100644 --- a/meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch +++ b/meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch @@ -7,6 +7,7 @@ Upstream-Status: Pending Signed-off-by: Roy Li Signed-off-by: Li Xin +Signed-off-by: Xiangyu Chen --- test/regress | 6 +++--- test/regress2 | 11 +++++------ @@ -20,7 +21,7 @@ index 2ce1705..d086a47 100755 if [ $numnodes -lt 2 ] ; then echo "need at least two nodes with at least $NEEDPAGES each of" echo "free memory for mempolicy regression tests" -+ echo "FAIL: numa regress" ++ echo "SKIP: numa regress" exit 77 # Skip test fi } diff --git a/meta/recipes-support/numactl/numactl/run-ptest b/meta/recipes-support/numactl/numactl/run-ptest index bf269da7559..e019b0d364e 100755 --- a/meta/recipes-support/numactl/numactl/run-ptest +++ b/meta/recipes-support/numactl/numactl/run-ptest @@ -8,7 +8,11 @@ if ! numactl -s | grep -q "No NUMA support available on this system."; then if numademo -t -e 10M; then echo "PASS: numademo" else - echo "FAIL: numademo" + if [ "$?" = 77 ] ; then + echo "SKIP: numademo" + else + echo "FAIL: numademo" + fi fi else echo "SKIP: ./../test/bind_range"