AgeCommit message (Collapse)Author
2020-10-19misc: add test for hasmntopt() option matchingHEADmasterYann Sionneau
Signed-off-by: Yann Sionneau <>
2020-10-15add c-sky tls macros from glibcWaldemar Brodkorb
2020-09-07fix gcc10 issueWaldemar Brodkorb
2020-04-27fix riscv macrosWaldemar Brodkorb
2020-04-27add riscv macros from glibcWaldemar Brodkorb
2020-04-06tls: add aarch64 macrosWaldemar Brodkorb
2020-04-05tls: make tls tests great againYann Sionneau
* TLS tests were "empty" because nothing was setting the following variables: * USE_TLS * HAVE___THREAD * HAVE_TLS_MODEL_ATTRIBUTE All toolchains supported by uClibc-ng today do support both NPTL threads and TLS. All ports also define HAVE_TLS_MODEL_ATTRIBUTE except alpha. * 3 tests (tst-tls6 / tst-tls7 / tst-tls8) were peeking into internal/private data structures from libc, which is not possible anymore since libc and tests are now split into 2 git repositories. This commit fixes those 2 issues so that TLS tests can be run again. Signed-off-by: Yann Sionneau <>
2020-04-05powerpc: update tls macros inline asm clobbersYann Sionneau
This was causing a compile error for powerpc64 toolchain because r3 was both listed as clobbered and as output in inline asm. Signed-off-by: Yann Sionneau <>
2020-04-05powerpc64: add missing tls macrosYann Sionneau
Signed-off-by: Yann Sionneau <>
2020-04-05or1k: add missing tls macrosYann Sionneau
Signed-off-by: Yann Sionneau <>
2019-10-29Merge remote-tracking branch 'github/master'Waldemar Brodkorb
2019-10-29Merge pull request #1 from ffontaine/masterWaldemar Brodkorb
Fix build with latest glibc
2019-10-29test/nptl/tst-mqueue4.c: fix build with latest glibcFabrice Fontaine
Fix the following error with latest glibc: In file included from /home/fabrice/buildroot/output/host/riscv32-buildroot-linux-gnu/sysroot/usr/include/mqueue.h:93:0, from tst-mqueue4.c:22: In function 'mq_open', inlined from 'do_test' at tst-mqueue4.c:174:6: /home/fabrice/buildroot/output/host/riscv32-buildroot-linux-gnu/sysroot/usr/include/bits/mqueue2.h:41:5: error: call to '__mq_open_wrong_number_of_args' declared with attribute error: mq_open can be called either with 2 or 4 arguments __mq_open_wrong_number_of_args (); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fixes: - Signed-off-by: Fabrice Fontaine <>
2019-10-29test/misc/test-nftw.c: fix build with latest glibcFabrice Fontaine
Fix the following error with latest glibc: In function 'open', inlined from 'do_test' at tst-nftw.c:38:10, inlined from 'main' at ../test-skeleton.c:318:12: /home/mark/buildroot-test/instance-0/output/host/riscv32-buildroot-linux-gnu/sysroot/usr/include/bits/fcntl2.h:50:4: error: call to '__open_missing_mode' declared with attribute error: open with O_CREAT or O_TMPFILE in second argument needs 3 arguments __open_missing_mode (); ^~~~~~~~~~~~~~~~~~~~~~ Fixes: - Signed-off-by: Fabrice Fontaine <>
2019-10-19avoid deadlock test in nsimdrv ARC simulatorWaldemar Brodkorb
2019-05-24be more conformant, from Timur.R.Mustafin@mcst.ruWaldemar Brodkorb
2019-05-13disable some looping testsWaldemar Brodkorb
2019-04-14Fix tst-mallocfork testYann Sionneau
This test was changed from using fork to vfork by: This change was wrong because man page says the child of vfork() must ONLY do either: - a call to one of exec(2) - a call to _exit(2) - get killed by a signal BUT the test case does: - a call to kill - and also a call to exit(3) and not _exit(2) This test produces a double free() causing assert in free because this is called several times: So, it seems wrong both in theory (according to man page) and in fact in practice (assert in free). Here I propose to get back to testing fork(), which is the original test case from: And to just "PASS" on no-mmu systems. For the record, here is the assert call stack: FAIL tst-mallocfork got 1 expected 0 ./tst-mallocfork: libc/stdlib/malloc-standard/malloc.c: 149: __do_check_inuse_chunk: Assertion `((((mchunkptr)(((char*)(p))+((p)->size & ~0x1)))->size) & 0x1)' failed. Didn't expect signal from child: got `Aborted' 0 free (mem=0x3a010) at libc/stdlib/malloc-standard/free.c:285 1 0x00000000000220c4 in __exit_handler (status=1) at libc/stdlib/_atexit.c:270 2 0x000000000001afa0 in __GI_exit (rv=1) at libc/stdlib/_atexit.c:301 3 0x0000000000010dcc in main (argc=1, argv=0x7ffffffd98) at ../test-skeleton.c:405 4 0x000000000001cba8 in __uClibc_main (main=0x10988 <main>, argc=1, argv=0x7ffffffd98, app_init=0x100e8, app_fini=0x23918 <_fini>, rtld_fini=0x0 <k1c_start>, stack_end=0x7ffffffd90) at libc/misc/internals/__uClibc_main.c:512 5 0x00000000000eb8b8 in ?? () Signed-off-by: Yann Sionneau <>
2018-12-31rt/tst-posix_spawn: fix random crash due to uninitialized varVineet Gupta
Seen on ARC when it passed in 1 setup, but segv on other | Path: /sd/arc_initramfs_hs_1812-gnu-2018.09-BIG/uClibc-ng-testsuite-Os/rt/tst-posix_spawn | CPU: 1 PID: 3313 Comm: tst-posix_spawn Not tainted | 4.19.0-00003-ga4e0cf751ad3 #108 | | [ECR ]: 0x00050100 => Invalid Read @ 0x00000000 by insn @ 0x20060c84 | [EFA ]: 0x00000000 | [BLINK ]: 0x20060bf4 | [ERET ]: 0x20060c84 | @off 0x52c84 in [/lib/] | VMA: 0x2000e000 to 0x20072000 Signed-off-by: Vineet Gupta <>
2018-11-25Add NO_CRYPT to fix build with glibc 2.28Fabrice Fontaine
Since glibc 2.28 (, the obsolete functions encrypt, encrypt_r, setkey, setkey_r, cbc_crypt, ecb_crypt, and des_setparity are no longer available to newly linked binaries, and the headers <rpc/des_crypt.h> and <rpc/rpc_des.h> are no longer installed. These functions encrypted and decrypted data with the DES block cipher, which is no longer considered secure. Software that still uses these functions should switch to a modern cryptography library, such as libgcrypt. So add a NO_CRYPT variable to disable test/crypt Fixes: - Signed-off-by: Fabrice Fontaine <>
2018-08-16disable complex mathWaldemar Brodkorb
2018-07-21Revert "arc: disable deadlocking test"Vineet Gupta
This seems to work fine on ARC ! This reverts commit f0567d67075ff7a27ada8ab5bce750fe8a739763. Signed-off-by: Vineet Gupta <>
2018-04-04remove tst-atomic*Waldemar Brodkorb
They cannot be enabled, because atomic.h is not exported and just an internal uClibc-ng header. Suggested-by: Alexey Brodkin <>
2018-03-14misc/tst-syscall6: fix build with musl and older kenrel headersBaruch Siach
The RWF_DSYNC and RWF_HIPRI macros were introduced in kernel version 4.6 with the preadv2/pwritev2 system calls. musl libc provides its own syscall definitions, even when the kernel headers are older. This leads to the following build failure: tst-syscall6.c: In function 'main': tst-syscall6.c:32:48: error: 'RWF_DSYNC' undeclared (first use in this function) nio = syscall(SYS_pwritev2, fd, iov, 2, 0, 0, RWF_DSYNC); ^~~~~~~~~ tst-syscall6.c:32:48: note: each undeclared identifier is reported only once for each function it appears in tst-syscall6.c:42:58: error: 'RWF_HIPRI' undeclared (first use in this function) nio = syscall(SYS_preadv2, fd, iov, 1, strlen(str0), 0, RWF_HIPRI); ^~~~~~~~~ Make the code depend also on RWF_HIPRI to fix this failure. Signed-off-by: Baruch Siach <>
2018-01-20add getcwd test from glibcWaldemar Brodkorb
2017-12-27add tls-macros for m68kWaldemar Brodkorb
2017-12-22fix compile errors with alphaWaldemar Brodkorb
2017-12-17rename librt test, add tst-posix_spawnWaldemar Brodkorb
2017-12-16tst-syscall*: Add tests for syscall() with varargsStafford Horne
Add tests in preparation for genericizing some of the architecture syscall() implementations. This was noticed when testing OR1K and found it had a broken syscall implementation. These tests try to cover the libc syscall() lqyer which has the purpose of passing the syscall number and arguments to the kernel. The actual kernel syscalls chosen have been selected for ease of testing. Signed-off-by: Stafford Horne <>
2017-12-16don't skip the testWaldemar Brodkorb
2017-12-10Fix subtle race in tst-cancel2 / tst-cancelx2Vineet Gupta
When ran on ARC, these tests would ocassionally fail | [ARCLinux]# for i in 1 2 3 4 5 ; do ./tst-cancel2; echo $?; done | write succeeded | result is wrong: expected 0xffffffff, got 0x1 | 1 <-- fail | 0 <-- pass | 0 <--- pass | 0 <-- pass | write succeeded | result is wrong: expected 0xffffffff, got 0x1 | 1 <-- fail Same test (which originated form glibc) doesn't fail in glibc builds. Turns out there's a subtle race in uclibc version The test creates a new thread, makes it do a looong write call, and parent then cancels the thread, expecting it to unwind out of write call cleanly. However the write (even for 10k bytes) could finish before parent gets a chance to resume and/or cancel it, causing the occasional failure. Fix this subtelty by making it write not just once but forever. Cc: Cupertino Miranda <> Signed-off-by: Vineet Gupta <>
2017-12-05Revert "or1k: disable some tests to complete test runs in qemu"Waldemar Brodkorb
This reverts commit 1502f8269bb8e58f8b29fb69af3a3b8c7b2532de.
2017-11-22tst-statfs: print f_frsize if availableEugene Rudoy
Follow-up of 68de9946e914d8c30dcc6667a059ea59e5b74cac Signed-off-by: Eugene Rudoy <>
2017-11-05arc: disable deadlocking testWaldemar Brodkorb
2017-10-26or1k: disable some tests to complete test runs in qemuWaldemar Brodkorb
Signed-off-by: Waldemar Brodkorb <>
2017-06-28sh: disable tests, stallingWaldemar Brodkorb
2017-05-12nptl: add new testcase for pthread_getcpuclockid()Waldemar Brodkorb
2017-05-11disable for glibcWaldemar Brodkorb
2017-01-28cleanup a little, disable a test for or1kWaldemar Brodkorb
2017-01-15add preadv/pwritev testWaldemar Brodkorb
2016-12-30add getnameinfo tests from GNU libcWaldemar Brodkorb
2016-12-24obstack removed, glibc compat is goneWaldemar Brodkorb
2016-12-18add iconv tests from glibc, enable one for uClibc-ng new libiconv, skip the ↵Waldemar Brodkorb
2016-12-18add missing include so that tests are not skippedWaldemar Brodkorb
2016-12-10fix compile error with glibc toolchainsWaldemar Brodkorb
2016-12-10fix compile error with glibc toolchainsWaldemar Brodkorb
2016-12-08disable xlocale testsWaldemar Brodkorb
2016-11-26we have to disable tst-tls2 for microblaze, qemu crashes otherwiseWaldemar Brodkorb
2016-11-26recognize big endian superh as shWaldemar Brodkorb
2016-11-22sh: disable some tests, we need to investigate later, tst-cond1 deadlocks on ↵Waldemar Brodkorb
glibc, too