Skip to contentSkip to conversation

package/rt-tests: disable for too old toolchains

PATCH New Romain Naour 2 participants 2 messages Jul 16, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/rt-tests: disable for too old toolchains

rt-tests doesn't build with some "old" toolchains due to missing local syscall number definition for the new kernel deadline scheduler on some architectures. Upsteam added __NR_sched_setattr and __NR_sched_setattr definition only for common architectures (x86, x86_64, arm) and tile if not already defined [1].

Instead of adding missing syscall number, avoid building rt-tests with toolchain compiled with too old kernel headers (i.e !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14)

At runtime, a 3.14 kernel must be used otherwise these syscall are not available.

[1]
https://kernel.googlesource.com/pub/scm/utils/rt-tests/rt-tests.git/+/ef2dee4232b7cae594ef7ecb7230c4bd18cea3f3

Fixes:
http://autobuild.buildroot.net/results/6fa/6facaeb10588bdf3ff029b882a8ae6ffba815cdc

---
 package/rt-tests/Config.in | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
package/rt-tests/Config.in +3 -2
index 08967ce..b39856d 100644
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_RT_TESTS
 	bool "rt-tests"
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
+	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14 # deadline scheduler syscall
 	depends on BR2_USE_MMU # fork()
 	depends on !BR2_STATIC_LIBS # dlopen
 	depends on !BR2_TOOLCHAIN_USES_MUSL # cyclictest
@@ -28,7 +29,7 @@ comment "rt-tests may not work on MIPS with an external uClibc toolchain"
 	depends on BR2_TOOLCHAIN_EXTERNAL_UCLIBC
 	depends on BR2_mips || BR2_mipsel || BR2_mips64 || BR2_mips64el
 
-comment "rt-tests needs a uClibc or glibc toolchain w/ NPTL, dynamic library"
+comment "rt-tests needs a uClibc or glibc toolchain w/ NPTL, headers >= 3.14, dynamic library"
 	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || BR2_STATIC_LIBS \
-		|| BR2_TOOLCHAIN_USES_MUSL
+		|| BR2_TOOLCHAIN_USES_MUSL || !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14
 	depends on BR2_USE_MMU
Signature · 1 line
2.5.5
#1 lore raw

PATCH 1/1 package/rt-tests: disable for too old toolchains

Hello,

Quoted 16 lines · Romain Naour

rt-tests doesn't build with some "old" toolchains due to missing local syscall number definition for the new kernel deadline scheduler on some architectures. Upsteam added __NR_sched_setattr and __NR_sched_setattr definition only for common architectures (x86, x86_64, arm) and tile if not already defined [1].

Instead of adding missing syscall number, avoid building rt-tests with toolchain compiled with too old kernel headers (i.e !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14)

At runtime, a 3.14 kernel must be used otherwise these syscall are not available.

[1]
https://kernel.googlesource.com/pub/scm/utils/rt-tests/rt-tests.git/+/ef2dee4232b7cae594ef7ecb7230c4bd18cea3f3

Quoted 7 lines

Fixes:
http://autobuild.buildroot.net/results/6fa/6facaeb10588bdf3ff029b882a8ae6ffba815cdc

---
 package/rt-tests/Config.in | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Applied to master, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com