Upgrade rt-tests to v1.8
cover Upgrade rt-tests to v1.8
rt-tests now requires numactl in order to successfully compile. Since numactl lives in meta-openembedded/meta-oe, it is added to oe-core as part of the patch series.
After numactl is successfully merged into oe-core, I intend to send a patch to remove it from meta-openembedded.
Randy Witt (4):
numactl: Add the recipe for numactl
numactl: Remove COMPATIBLE_HOST restrictions
numactl: Skip the ptests when numa is not supported
rt-tests: Update recipes to use 1.8
...Allow-for-CC-and-AR-to-be-overridden.patch | 28 +++++
...{hwlatdetect_1.1.bb => hwlatdetect_1.8.bb} | 0
...gzip-with-n-for-build-reproducibilty.patch | 62 -----------
meta/recipes-rt/rt-tests/rt-tests.inc | 11 +-
.../{rt-tests_1.1.bb => rt-tests_1.8.bb} | 9 +-
.../numactl/0001-define-run-test-target.patch | 32 ++++++
...1-numademo-fix-error-on-32bit-system.patch | 100 ++++++++++++++++++
.../numactl/Fix-the-test-output-format.patch | 64 +++++++++++
meta/recipes-support/numactl/numactl/Makefile | 7 ++
.../recipes-support/numactl/numactl/run-ptest | 23 ++++
meta/recipes-support/numactl/numactl_git.bb | 57 ++++++++++
11 files changed, 318 insertions(+), 75 deletions(-)
create mode 100644 meta/recipes-rt/rt-tests/files/0001-Makefile-Allow-for-CC-and-AR-to-be-overridden.patch
rename meta/recipes-rt/rt-tests/{hwlatdetect_1.1.bb => hwlatdetect_1.8.bb} (100%)
delete mode 100644 meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch
rename meta/recipes-rt/rt-tests/{rt-tests_1.1.bb => rt-tests_1.8.bb} (70%)
create mode 100644 meta/recipes-support/numactl/numactl/0001-define-run-test-target.patch
create mode 100644 meta/recipes-support/numactl/numactl/0001-numademo-fix-error-on-32bit-system.patch
create mode 100644 meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch
create mode 100644 meta/recipes-support/numactl/numactl/Makefile
create mode 100755 meta/recipes-support/numactl/numactl/run-ptest
create mode 100644 meta/recipes-support/numactl/numactl_git.bbSignature · 1 line
2.26.2
PATCH 1/4 numactl: Add the recipe for numactl
From: Randy Witt <[email protected]>
This is a direct copy of numactl from meta-openembedded. numactl is being moved to oe-core since the latest versions of rt-tests(which is in oe-core) require libnuma.
--- .../numactl/0001-define-run-test-target.patch | 32 ++++++ ...1-numademo-fix-error-on-32bit-system.patch | 100 ++++++++++++++++++ .../numactl/Fix-the-test-output-format.patch | 64 +++++++++++ meta/recipes-support/numactl/numactl/Makefile | 7 ++ .../recipes-support/numactl/numactl/run-ptest | 9 ++ meta/recipes-support/numactl/numactl_git.bb | 60 +++++++++++ 6 files changed, 272 insertions(+) create mode 100644 meta/recipes-support/numactl/numactl/0001-define-run-test-target.patch create mode 100644 meta/recipes-support/numactl/numactl/0001-numademo-fix-error-on-32bit-system.patch create mode 100644 meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch create mode 100644 meta/recipes-support/numactl/numactl/Makefile create mode 100755 meta/recipes-support/numactl/numactl/run-ptest create mode 100644 meta/recipes-support/numactl/numactl_git.bb
meta/recipes-support/numactl/numactl/0001-define-run-test-target.patch new file +32 -0
@@ -0,0 +1,32 @@ +rename test target as run-test + +Upstream-Statue: Pending + +test target not only compile the test files, but also run them, which is +not suitable for cross-compile environment, so rename it as run-test. + +and define test target to compile the test files. + +Signed-off-by: Roy Li <[email protected]> +--- + Makefile.am | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/Makefile.am b/Makefile.am +index b6db339..de176c4 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -124,7 +124,9 @@ regress2: $(check_PROGRAMS) + test_numademo: numademo + ./numademo -t -e 10M + +-test: all $(check_PROGRAMS) regress1 regress2 test_numademo ++test: all $(check_PROGRAMS) ++ ++run-test: all $(check_PROGRAMS) regress1 regress2 test_numademo + + TESTS_ENVIRONMENT = builddir='$(builddir)'; export builddir; + +-- +1.9.1 +
meta/recipes-support/numactl/numactl/0001-numademo-fix-error-on-32bit-system.patch new file +100 -0
100 lines not on this page · raw message
meta/recipes-support/numactl/numactl/Fix-the-test-output-format.patch new file +64 -0
64 lines not on this page · raw message
meta/recipes-support/numactl/numactl/Makefile new file +7 -0
@@ -0,0 +1,7 @@ +.PHONY: regress1 regress2 + +regress1: + cd test ; ./regress + +regress2: + cd test ; ./regress2
meta/recipes-support/numactl/numactl/run-ptest new file +9 -0
@@ -0,0 +1,9 @@ +#!/bin/sh +make regress1 +make regress2 +if numademo -t -e 10M; then + echo "PASS: numademo" +else + echo "FAIL: numademo" +fi +
meta/recipes-support/numactl/numactl_git.bb new file +60 -0
60 lines not on this page · raw message
Signature · 1 line
2.26.2
PATCH 2/4 numactl: Remove COMPATIBLE_HOST restrictions
In reply to Randy WittFrom: Randy Witt <[email protected]>
Since there may be recipes that depend on libnuma, even though the hardware doesn't support numa, remove the COMPATIBLE_HOST restrictions.
--- meta/recipes-support/numactl/numactl_git.bb | 3 --- 1 file changed, 3 deletions(-)
meta/recipes-support/numactl/numactl_git.bb +0 -3
@@ -23,9 +23,6 @@ SRC_URI = "git://github.com/numactl/numactl \ S = "${WORKDIR}/git" -# ARM does not currently support NUMA -COMPATIBLE_HOST = "^((?!arm).*)$" - do_install() { oe_runmake DESTDIR=${D} prefix=${D}/usr install #remove the empty man2 directory
Signature · 1 line
2.26.2
PATCH 3/4 numactl: Skip the ptests when numa is not supported
In reply to Randy WittFrom: Randy Witt <[email protected]>
When numa is not supported, there is no reason to run the ptests since they will fail. While the best scenario would be for the upstream tests to skip themselves when numa is not supported, for now skip them in run-ptest.
--- .../recipes-support/numactl/numactl/run-ptest | 24 +++++++++++++++---- 1 file changed, 19 insertions(+), 5 deletions(-)
meta/recipes-support/numactl/numactl/run-ptest +19 -5
@@ -1,9 +1,23 @@ #!/bin/sh -make regress1 -make regress2 -if numademo -t -e 10M; then - echo "PASS: numademo" + +# If there is numa support, run the tests. Otherwise skip all the tests. +# Ideally the skipping would happen by the upstream tests. +if ! numactl -s | grep -q "No NUMA support available on this system."; then + make regress1 + make regress2 + if numademo -t -e 10M; then + echo "PASS: numademo" + else + echo "FAIL: numademo" + fi else - echo "FAIL: numademo" + echo "SKIP: ./../test/bind_range" + echo "SKIP: ./../test/checkaffinity" + echo "SKIP: ./../test/checktopology" + echo "SKIP: ./../test/distance" + echo "SKIP: ./../test/nodemap" + echo "SKIP: ./../test/tbitmap" + echo "SKIP: numactl_regress" + echo "SKIP: numademo" fi
Signature · 1 line
2.26.2
PATCH 4/4 rt-tests: Update recipes to use 1.8
In reply to Randy WittFrom: Randy Witt <[email protected]>
John Kacur(the maintainer of rt-tests), recommends "that they use unstable/devel/latest as the maintained stable branch". I received this information on IRC, I couldn't find it documented anywhere else.
This means that both rt-tests and hwlatdetect can be updated to be 1.8, the latest release on unstable/devel/latest.
0001-gzip-with-n-for-build-reproducibilty.patch was removed because upstream now uses "gzip -n" by default.
---
...Allow-for-CC-and-AR-to-be-overridden.patch | 28 +++++++++
...{hwlatdetect_1.1.bb => hwlatdetect_1.8.bb} | 0
...gzip-with-n-for-build-reproducibilty.patch | 62 -------------------
meta/recipes-rt/rt-tests/rt-tests.inc | 11 +---
.../{rt-tests_1.1.bb => rt-tests_1.8.bb} | 9 ++-
5 files changed, 35 insertions(+), 75 deletions(-)
create mode 100644 meta/recipes-rt/rt-tests/files/0001-Makefile-Allow-for-CC-and-AR-to-be-overridden.patch
rename meta/recipes-rt/rt-tests/{hwlatdetect_1.1.bb => hwlatdetect_1.8.bb} (100%)
delete mode 100644 meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch
rename meta/recipes-rt/rt-tests/{rt-tests_1.1.bb => rt-tests_1.8.bb} (70%)meta/recipes-rt/rt-tests/files/0001-Makefile-Allow-for-CC-and-AR-to-be-overridden.patch new file +28 -0
@@ -0,0 +1,28 @@ +From caaa142826504ad0375f9d21c558f10f31305cdb Mon Sep 17 00:00:00 2001 +From: Randy Witt <[email protected]> +Date: Fri, 16 Oct 2020 16:54:30 -0700 +Subject: [PATCH] Makefile: Allow for CC and AR to be overridden + +The Makefile previously allowed for this but it was removed upstream in +commit 7763cf316d7896fa05b816a46998f0827ab6e6eb. + +Signed-off-by: Randy Witt <[email protected]> + +Upstream-Status: Inappropriate [other] +--- + Makefile | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Makefile b/Makefile +index 05fc5ed..7a289c8 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,6 +1,6 @@ + VERSION = 1.8 +-CC = $(CROSS_COMPILE)gcc +-AR = $(CROSS_COMPILE)ar ++CC ?= $(CROSS_COMPILE)gcc ++AR ?= $(CROSS_COMPILE)ar + + OBJDIR = bld +
meta/recipes-rt/rt-tests/hwlatdetect_1.8.bb renamed from meta/recipes-rt/rt-tests/hwlatdetect_1.1.bb +0 -0
meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch deleted +0 -62
62 lines not on this page · raw message
meta/recipes-rt/rt-tests/rt-tests.inc +3 -8
@@ -1,12 +1,7 @@ -# Version 1.1 -SRCREV = "dff174f994f547a5785d32454865f140daacb0f5" +# Version 1.8 +SRCREV = "9f78b91f057e63b0c241012ce36b57168133eefb" PE = "1" -SRC_URI = "git://git.kernel.org/pub/scm/utils/rt-tests/rt-tests.git" -# 1.2 and up seem to be development versions -UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>(?!1\.[2-8])(\d+(\.\d+)+))" +SRC_URI = "git://git.kernel.org/pub/scm/utils/rt-tests/rt-tests.git;branch=unstable/devel/latest" S = "${WORKDIR}/git" - -# calling 'uname -m' is broken on crossbuilds -EXTRA_OEMAKE = "NUMA=0"
meta/recipes-rt/rt-tests/rt-tests_1.8.bb renamed from meta/recipes-rt/rt-tests/rt-tests_1.1.bb +4 -5
@@ -1,11 +1,9 @@ SUMMARY = "Real-Time preemption testcases" HOMEPAGE = "https://rt.wiki.kernel.org/index.php/Cyclictest" SECTION = "tests" -DEPENDS = "linux-libc-headers virtual/libc" +DEPENDS = "linux-libc-headers virtual/libc numactl" LICENSE = "GPLv2 & GPLv2+" -LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ - file://src/cyclictest/cyclictest.c;beginline=7;endline=9;md5=e768b8da44555fe63f65e5c497844cb5 \ - file://src/pi_tests/pi_stress.c;beginline=6;endline=19;md5=bd426a634a43ec612e9fbf125dfcc949" +LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" require rt-tests.inc inherit ptest
@@ -13,7 +11,7 @@ inherit ptest SRC_URI += " \ file://run-ptest \ file://rt_bmark.py \ - file://0001-gzip-with-n-for-build-reproducibilty.patch \ + file://0001-Makefile-Allow-for-CC-and-AR-to-be-overridden.patch \ " # rt-tests needs PI mutex support in libc
@@ -34,3 +32,4 @@ do_install_ptest() { RDEPENDS_${PN}-ptest += " stress-ng python3 python3-multiprocessing python3-datetime python3-misc" FILES_${PN} += "${prefix}/src/backfire" +RDEPENDS_${PN} += "bash"
Signature · 1 line
2.26.2