summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/nolibc
AgeCommit message (Collapse)Author
2025-03-07selftests/nolibc: stop testing constructor orderThomas Weißschuh
The execution order of constructors in undefined and depends on the toolchain. While recent toolchains seems to have a stable order, it doesn't work for older ones and may also change at any time. Stop validating the order and instead only validate that all constructors are executed. Reported-by: Willy Tarreau <w@1wt.eu> Closes: https://lore.kernel.org/lkml/20250301110735.GA18621@1wt.eu/ Link: https://lore.kernel.org/r/20250306-nolibc-constructor-order-v1-1-68fd161cc5ec@weissschuh.net Acked-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-03-06selftests/nolibc: use O_RDONLY flag instead of 0Louis Taylor
This doesn't matter much, but is what the standard says. Signed-off-by: Louis Taylor <louis@kragniz.eu> Link: https://lore.kernel.org/r/20250306184147.208723-5-louis@kragniz.eu Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-03-06tools/nolibc: add support for openat(2)Louis Taylor
openat is useful to avoid needing to construct relative paths, so expose a wrapper for using it directly. Signed-off-by: Louis Taylor <louis@kragniz.eu> Link: https://lore.kernel.org/r/20250306184147.208723-1-louis@kragniz.eu Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-03-02selftests/nolibc: add armthumb configurationThomas Weißschuh
While nolibc does support ARM Thumb instructions, that support was not tested specifically. Add a new test configuration for it. Tested-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250301-nolibc-armthumb-v1-2-d1f04abb5f6d@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-03-02selftests/nolibc: explicitly enable ARM modeThomas Weißschuh
The default could also be -mthumb. Explicitly use -marm to keep everything predictable. Tested-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250301-nolibc-armthumb-v1-1-d1f04abb5f6d@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-26tools/nolibc: add support for [v]sscanf()Thomas Weißschuh
These functions are used often, also in selftests. sscanf() itself is also used by kselftest.h itself. The implementation is limited and only supports numeric arguments. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250209-nolibc-scanf-v2-1-c29dea32f1cd@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-20tools/nolibc: add support for 32-bit s390Thomas Weißschuh
32-bit s390 is very close to the existing 64-bit implementation. Some special handling is necessary as there is neither LLVM nor QEMU support. Also the kernel itself can not build natively for 32-bit s390, so instead the test program is executed with a 64-bit kernel. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250206-nolibc-s390-v2-2-991ad97e3d58@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-20selftests/nolibc: rename s390 to s390xThomas Weißschuh
Support for 32-bit s390 is about to be added. As "s39032" would look horrible, use the another naming scheme. 32-bit s390 is "s390" and 64-bit s390 is "s390x", similar to how it is handled in various toolchain components. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250206-nolibc-s390-v2-1-991ad97e3d58@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-20selftests/nolibc: only run constructor tests on nolibcThomas Weißschuh
The nolibc testsuite can be run against other libcs to test for interoperability. Some aspects of the constructor execution are not standardized and musl does not provide all tested feature, for one it does not provide arguments to the constructors, anymore? Skip the constructor tests on non-nolibc configurations. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250212-nolibc-test-constructor-v1-1-c963875b3da4@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-12selftests/nolibc: split up architecture list in run-tests.shThomas Weißschuh
The list is getting overly long and any modifications introduce a lot of noise and are prone to conflicts. Split the string into a bash array and break that into multiple lines. Link: https://lore.kernel.org/r/20250211-nolibc-test-archs-v1-1-8e55aa3369cf@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-09tools/nolibc: add support for directory accessThomas Weißschuh
Add an implementation for directory access operations. To keep nolibc itself allocation-free, a "DIR *" does not point to any data, but directly encodes a filedescriptor number, equivalent to "FILE *". Without any per-directory storage it is not possible to implement readdir() POSIX confirming. Instead only readdir_r() is provided. While readdir_r() is deprecated in glibc, the reasons for that are not applicable to nolibc. Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Link: https://lore.kernel.org/r/20250209-nolibc-dir-v2-2-57cc1da8558b@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: always keep test kernel configuration up to dateThomas Weißschuh
Avoid using a stale test kernel configuration by always synchronizing it to the current source tree. kbuild is smart enough to avoid spurious rebuilds. Shuffle the code around a bit to keep all the commands with side-effects together. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-5-5701c35995d6@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: execute defconfig before other targetsThomas Weißschuh
Some targets use the test kernel configuration. Executing defconfig in the same make invocation as those targets results in errors as the configuration may be in an inconsistent state during reconfiguration. Avoid this by introducing ordering dependencies between the defconfig and some other targets. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-4-5701c35995d6@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: drop call to mrproper targetThomas Weißschuh
"mrproper" unnecessarily cleans a lot of files. kbuild is smart enough to handle changed configurations, so the cleanup is not necessary and only leads to excessive rebuilds. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-3-5701c35995d6@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: drop call to prepare targetThomas Weißschuh
The "prepare" target does not need to be run manually. kbuild knows when to use it on its own and the target is not even documented. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-2-5701c35995d6@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: drop mips32be EXTRACONFIGThomas Weißschuh
kbuild already contains logic to merge predefines snippets into a defconfig file. For MIPS a snippet for big-endian is already provided. Link: https://lore.kernel.org/r/20250123-nolibc-config-v2-1-5701c35995d6@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: enable -Wmissing-prototypesThomas Weißschuh
User code may want to use this compiler flag. Make sure it is supported by nolibc. Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-prototype-v1-3-e1afc5c1999a@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-02-03selftests/nolibc: ignore -Wmissing-prototypesThomas Weißschuh
To make sure nolibc itself is compatible with -Wmissing-prototypes the compiler flag should be enabled when building nolibc-test. However some of its functions are non-static to ease debugging [0], triggering the compiler warning. Disable the warning inside nolibc-test while still enabling it for nolibc itself. [0] https://lore.kernel.org/lkml/ZMjM0UPRAqoC+goY@1wt.eu/ Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20250123-nolibc-prototype-v1-2-e1afc5c1999a@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-13selftests/nolibc: add configurations for riscv32Thomas Weißschuh
nolibc already supports riscv32. Wire it up in the testsuite. Link: https://lore.kernel.org/r/20241221-nolibc-rv32-v1-6-d9ef6dab7c63@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-13selftests/nolibc: rename riscv to riscv64Thomas Weißschuh
riscv32 support is about the be added. To keep the naming clear and consistent with other architectures rename riscv to riscv64, as that is what it actually represents. Link: https://lore.kernel.org/r/20241221-nolibc-rv32-v1-5-d9ef6dab7c63@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-13selftests/nolibc: skip tests for unimplemented syscallsThomas Weißschuh
The riscv32 architecture is missing many of the older syscalls. Instead of providing wrappers for everything at once, introducing a lot of complexity, skip the tests for those syscalls for now. Link: https://lore.kernel.org/r/20241221-nolibc-rv32-v1-4-d9ef6dab7c63@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-13selftests/nolibc: use a pipe to in vfprintf testsThomas Weißschuh
Not all architectures implement lseek(), for example riscv32 only implements llseek() which is not equivalent to normal lseek(). Remove the need for lseek() by using a pipe instead. Link: https://lore.kernel.org/r/20241221-nolibc-rv32-v1-3-d9ef6dab7c63@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-13selftests/nolibc: use waitid() over waitpid()Thomas Weißschuh
Newer archs like riscv32 don't provide waitpid() anymore. Switch to waitid() which is available everywhere. Link: https://lore.kernel.org/r/20241221-nolibc-rv32-v1-2-d9ef6dab7c63@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2025-01-08selftests/nolibc: run-tests.sh: detect missing toolchainWilly Tarreau
The script tries to resolve the path to the current toolchain using realpath, which fails in case it's not installed, and since it's run under -e, it doesn't have the opportunity to display a help message. Let's detect the absence of the required toolchain before running that command and provide a friendlier message when this happens. Link: https://lore.kernel.org/all/ZtlQbpgpn9OQOPyI@1wt.eu/ Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-10-07selftests/nolibc: start qemu with 1 GiB of memoryThomas Weißschuh
Recently the loongarch defconfig stopped working with the default 128 MiB of memory. The VM just spins infinitively. Increasing the available memory to 1 GiB, similar to s390, fixes the issue. To avoid having to do this for each architecture on its own, proactively apply to all architectures. Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Link: https://lore.kernel.org/r/20241007-nolibc-qemu-mem-v1-1-c1c2f9acd0f8@linutronix.de Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: run-tests.sh: allow building through LLVMThomas Weißschuh
The nolibc tests can now be properly built with LLVM. Expose this through run-tests.sh. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-15-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: use correct clang target for s390/systemzThomas Weißschuh
The target names between GCC and clang differ for s390. While GCC uses "s390", clang uses "systemz". This mapping is not handled by tools/scripts/Makefile.include, so do it in the nolibc-test Makefile. Acked-by: Willy Tarreau <w@1wt.eu> Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-14-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: don't use libgcc when building with clangThomas Weißschuh
The logic in clang to find the libgcc.a from a GCC toolchain for a specific ABI does not work reliably and can lead to errors. Instead disable libgcc when building with clang, as it's not needed anyways. Acked-by: Willy Tarreau <w@1wt.eu> Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-13-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: run-tests.sh: avoid overwriting CFLAGS_EXTRAThomas Weißschuh
If the user specified their own CFLAGS_EXTRA these should not be overwritten by `-e`. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-12-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: add cc-option compatible with clang cross buildsThomas Weißschuh
The cc-option macro from Build.include is not compatible with clang cross builds, as it does not respect the "--target" and similar flags, set up by Mekfile.include. Provide a custom variant which works correctly. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-11-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: add support for LLVM= parameterThomas Weißschuh
Makefile.include can modify CC and CFLAGS for usage with clang. Make use of it. Makefile.include is currently used to handle the O= variable. This is incompatible with the LLVM= handling as for O= it has to be included as early as possible, while for LLVM= it needs to be included after CFLAGS are set up. To avoid this incompatibility, switch the O= handling to custom logic. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-10-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: determine $(srctree) firstThomas Weißschuh
The nolibc-test Makefile includes various other Makefiles from the tree. At first these are included with relative paths like "../../../build/Build.include" but as soon as $(srctree) is set up, the inclusions use that instead to build full paths. To keep the style of inclusions consistent, perform the setup $(srctree) as early as possible and use it for all inclusions. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-9-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: avoid passing NULL to printf("%s")Thomas Weißschuh
Clang on higher optimization levels detects that NULL is passed to printf("%s") and warns about it. While printf() from nolibc gracefully handles that NULL, it is undefined behavior as per POSIX, so the warning is reasonable. Avoid the warning by transforming NULL into a non-NULL placeholder. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-8-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-12selftests/nolibc: report failure if no testcase passedThomas Weißschuh
When nolibc-test is so broken, it doesn't even start, don't report success. Reviewed-by: Shuah Khan <skhan@linuxfoundation.org> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240807-nolibc-llvm-v2-7-c20f2f5fc7c2@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-08-09tools/nolibc: pass argc, argv and envp to constructorsThomas Weißschuh
Since 2005 glibc has passed argc, argv, and envp to all constructors. As it is cheap and easy to do so, mirror that behaviour in nolibc. This makes it easier to migrate applications to nolibc. Link: https://lore.kernel.org/r/20240728-nolibc-constructor-args-v1-1-36d0bf5cd4c0@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-06-29tools/nolibc: implement strerror()Thomas Weißschuh
strerror() is commonly used. For example in kselftest which currently needs to do an #ifdef NOLIBC to handle the lack of strerror(). Keep it simple and reuse the output format of perror() for strerror(). Acked-by: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-06-29selftests/nolibc: introduce condition to run tests only on nolibcThomas Weißschuh
Some tests only make sense on nolibc. To avoid gaps in the test numbers do to inline "#ifdef NOLIBC", add a condition to formally skip these tests. Acked-by: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-06-29tools/nolibc: implement strtol() and friendsThomas Weißschuh
The implementation always works on uintmax_t values. This is inefficient when only 32bit are needed. However for all functions this only happens for strtol() on 32bit platforms. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240425-nolibc-strtol-v1-2-bfeef7846902@weissschuh.net
2024-06-29selftests/nolibc: run-tests.sh: use -Werror by defaultThomas Weißschuh
run-tests.sh hides the output from the compiler unless the compilation fails. To recognize newly introduced warnings use -Werror by default. Also add a switch to disable -Werror in case the warnings are expected. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240423-nolibc-werror-v1-1-e6f0bd66eb45@weissschuh.net
2024-06-29selftests/nolibc: disable brk()/sbrk() tests on muslThomas Weißschuh
On musl calls to brk() and sbrk() always fail with ENOMEM. Detect this and skip the tests on musl. Tested on glibc 2.39 and musl 1.2.5 in addition to nolibc. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Acked-by: Willy Tarreau <w@1wt.eu> Link: https://lore.kernel.org/r/20240424-nolibc-musl-brk-v1-1-b49882dd9a93@weissschuh.net
2024-06-29selftests/nolibc: fix printf format mismatch in expect_str_buf_eq()Thomas Weißschuh
Fix the following compiler warning on 32bit: i386-linux-gcc -Os -fno-ident -fno-asynchronous-unwind-tables -std=c89 -W -Wall -Wextra -fno-stack-protector -m32 -mstack-protector-guard=global -fstack-protector-all -o nolibc-test \ -nostdlib -nostdinc -static -Isysroot/i386/include nolibc-test.c nolibc-test-linkage.c -lgcc nolibc-test.c: In function 'expect_str_buf_eq': nolibc-test.c:610:30: error: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'size_t' {aka 'unsigned int'} [-Werror=format=] 610 | llen += printf(" = %lu <%s> ", expr, buf); | ~~^ ~~~~ | | | | | size_t {aka unsigned int} | long unsigned int | %u Fixes: 1063649cf531 ("selftests/nolibc: Add tests for strlcat() and strlcpy()") Cc: stable@vger.kernel.org Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2024-04-14tools/nolibc: add support for uname(2)Thomas Weißschuh
All supported kernels are assumed to use struct new_utsname. This is validated in test_uname(). uname(2) can for example be used in ksft_min_kernel_version() from the kernels selftest framework. Link: https://lore.kernel.org/lkml/20240412123536.GA32444@redhat.com/ Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Acked-by: Willy Tarreau <w@1wt.eu>
2024-04-10selftests/nolibc: Add tests for strlcat() and strlcpy()Rodrigo Campos
I've verified that the tests matches libbsd's strlcat()/strlcpy() implementation. Please note that as strlcat()/strlcpy() are not part of the libc, the tests are only compiled when using nolibc. Signed-off-by: Rodrigo Campos <rodrigo@sdfg.com.ar> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2023-12-11selftests/nolibc: disable coredump via setrlimitThomas Weißschuh
qemu-user does has its own implementation of coredumping. That implementation does not respect the call to prctl(PR_SET_DUMPABLE, 0) in run_protection(). This leads to a coredump for every test run under qemu-user. Use also setrlimit() to inhibit coredump creation which is respected by qemu-user. Link: https://lore.kernel.org/qemu-devel/20231115-qemu-user-dumpable-v1-2-edbe7f0fbb02@t-8ch.de/ Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Link: https://lore.kernel.org/lkml/20231123-nolibc-rlimit-v1-3-a428b131de2a@weissschuh.net/ Acked-by: Willy Tarreau <w@1wt.eu>
2023-12-11tools/nolibc: add support for getrlimit/setrlimitThomas Weißschuh
The implementation uses the prlimit64 systemcall as that is available on all architectures. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Link: https://lore.kernel.org/lkml/20231123-nolibc-rlimit-v1-2-a428b131de2a@weissschuh.net/ Acked-by: Willy Tarreau <w@1wt.eu>
2023-12-11tools/nolibc: drop duplicated testcase ioctl_tiocinqThomas Weißschuh
The same testcase is present on the line above. Fixes: b4844fa0bdb4 ("selftests/nolibc: implement a few tests for various syscalls") Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2023-12-11selftests/nolibc: make result alignment more robustThomas Weißschuh
Move the check of the existing length into the function so it can't be forgotten by the caller. Also hardcode the padding character as only spaces are ever used. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2023-12-11tools/nolibc: mips: add support for PICThomas Weißschuh
MIPS requires some extra instructions to set up the $gp register for the with a pointer to the global data area. This isn't needed for non-PIC builds, but this patch enables the code unconditionally to prevent bitrot. Also enable PIC in one of the test configurations for ongoing validation. Link: https://lore.kernel.org/r/20231108-nolibc-pic-v2-1-4fb0d6284757@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2023-12-11selftests/nolibc: run-tests.sh: enable testing via qemu-userThomas Weißschuh
qemu-user is faster than a full system test. Link: https://lore.kernel.org/r/20770915-nolibc-run-user-v1-2-3caec61726dc@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
2023-12-11selftests/nolibc: introduce QEMU_ARCH_USERThomas Weißschuh
While ppc64le shares the same executable with regular ppc64 the user variant needs has a dedicated executable. Introduce a new QEMU_ARCH_USER Makefile variable to accommodate that. Fixes: 17362f3d0bd3 ("selftests/nolibc: use qemu-system-ppc64 for ppc64le") Link: https://lore.kernel.org/r/20770915-nolibc-run-user-v1-1-3caec61726dc@weissschuh.net Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>