Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
This reverts commit c13f823941b103cf744929e5afcb3e2bc1342354.
|
|
There is not possible to use use fork() on noMMU target, so exporting
pthread_atfork() for such target is useless.
A program using pthread_atfork() will likely fail at runtime due to the
error code returned by this function.
Signed-off-by: Romain Naour <romain.naour@gmail.com>
|
|
These functions are used by firefox for example.
Tested with running firefox on x86 system.
|
|
Only static linking is supported for now.
More debugging and analyzing for ld.so, TLS and NPTL
is required. But at least you can bootup a static
root fileystem in Qemu.
|
|
Not perfect, but a starting point.
Some tests of the test suite are failing.
|
|
Somehow this got removed with f1d7505e40654a185843bdc8f1cf1fd00ab55c04.
Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
|
There was a deadlock hanging in a sycall to futex,
which should be solved now.
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
Despite the prev fix, tst-mqueue3 was still segfaulting.
The issue was BLINK register not restored properly for return
00002690 <mq_timedsend>:
2690: sub r9,r25,0x448
2698: ld r10,[r9]
269c: cmp r10,0
26a0: beq -36
26a4: st.aw blink,[sp,-4]
26a8: st.aw r0,[sp,-4]
26ac: st.aw r1,[sp,-4]
26b0: st.aw r2,[sp,-4]
26b4: st.aw r3,[sp,-4]
26b8: st.aw r4,[sp,-4]
26bc: bl 1e28 <__librt_enable_asynccancel>
26c0: mov r9,r0
26c4: ld.ab r4,[sp,4]
26c8: ld.ab r3,[sp,4]
26cc: ld.ab r2,[sp,4]
26d0: ld.ab r1,[sp,4]
26d4: ld.ab r0,[sp,4]
26d8: ld.ab blink,[sp, 4] <---- function return BLINK
26dc: mov r8,182
26e0: trap_s 0
26e2: cmp r0,-1024
26e6: st.aw r0,[sp,-4]
26ea: mov r0,r9
26ee: bl 1e90 <__librt_disable_asynccancel> <-- BLINK clobbered
to next PC
26f2: ld.ab r0,[sp,4] <----| loops here until sp is out of bound
26fa: cmp r0,-1024 |
26fe: jls [blink] -----|
2702: b 15d8
2706: nop_s
So the fix was to retain BLINK on stack before function call, and pop it
later
- 26d8: ld.ab blink,[sp, 4]
+ 26d8: ld blink,[sp] <--- restore BLINK, but retain on stack
26dc: mov r8,182
26e0: trap_s 0
26e2: cmp r0,-1024
26e6: st.aw r0,[sp,-4]
26ea: mov r0,r9
26ee: bl 1e90 <__librt_disable_asynccancel>
26f2: ld.ab r0,[sp,4]
+ 26f6: ld.ab blink,[sp,4] <--- finally pop BLINK
26fa: cmp r0,-1024
26fe: jls [blink]
Reported-by: Eugeniy Paltsev <paltsev@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
|
|
This was reported as uClibc test suite failures of tst-mqueue3 and
tst-mqueue5.
The syscall args were getting clobbered, so use scratch regs which are
not used for syscall args
00002690 <mq_timedsend>:
; SINGLE_THREAD_P
2690: sub r1,r25,0x448 <--- clobers r1, r2
2698: ld r2,[r1]
269c: cmp r2,0
26a0: bz mq_timedsend_nocancel
; DOCARGS (saves syscall args but r1, r2 clobbered already)
26a4: st.aw blink,[sp,-4]
26a8: st.aw r0,[sp,-4]
26ac: st.aw r1,[sp,-4]
26b0: st.aw r2,[sp,-4]
26b4: st.aw r3,[sp,-4]
26b8: st.aw r4,[sp,-4]
26bc: bl 1e28 <__librt_enable_asynccancel>
Reported-by: Eugeniy Paltsev <paltsev@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
|
|
The nested libpthread_nonshared.a and libdl.os shouldn't be included
in the static libc.a. Fixes compile issues for static builds.
|
|
Remove powerpc64 bits as we only support powerpc32.
|
|
Similar to musl libc a single libc has many benefits and solves
some open issues with uClibc-ng.
- no pthread_mutex_* weak symbols exported anymore
- applications no longer failing to link when either
-lrt or -lpthread are missing for dynamic and static linking mode
- smaller C library
- slightly better runtime performance
|
|
Seems better and more stable.
|
|
We do not support 2.4 Linux kernels anyway, and almost
all newer 2.6 kernels should have tgkill syscall.
Cleanup the raise situation, pt-raise.c is unused, sync
raise.c with latest GNU libc.
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
The code was disabled a while ago in commit:
814b0901f460a246315bfa7933a661f415bdc7fa
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
[ glibc commit d3c7e68655 ]
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
This is useful to build native gcc on targets supporting
Linuxthreads instead of NPTL.
|
|
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
|
|
As this is only implemented for a few architecture and not well
tested, just remove it.
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
|
|
Add test case for the deadlock detection.
Reported-By: Martin Willi <martin@strongswan.org>
|
|
Add support for Andes Technology NDS32 architecture.
See here http://www.andestech.com/en/index/index.htm for more
informaton. Verification of the port from an older uClibc
port was done on a sponsored AG101p board.
The testsuite only has 5 errors, three are related to
an existing bug in dlclose() with LT.old, also happening
on cris32 and m68k.
Failures to fallocate/posix_fallocate are unresolved.
Thanks to Andes Technology sponsoring the hardware and
being very helpful while doing the uClibc-ng porting.
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
Simplify the switch from uClibc to uClibc-ng.
Apps already built against uClibc-0.9.x.y require .so.0
libs to present on target which in case of current uClibc-ng is
not the case and those apps could not be run.
This change creates symlinks from .so.1 to .so.0 for
most of other libs in the same way as it was done by
23e96d89b6ab "ldso: install backward compatibility symlink by default"
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Waldemar Brodkorb <wbx@uclibc-ng.org>
Cc: Vineet Gupta <vgupta@synopsys.com>
Cc: Anton Kolesov <akolesov@synopsys.com>
|
|
|
|
Simplify and use generic lowlevellock.
Tested-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Simplify and use generic lowlevellock.
Tested-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Simplify and use generic lowlevellock.
Tested-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
lowlevellock.c for arm differs from the generic lowlevellock.c only in
insignificant ways, so can be removed. Follow glibc commit 6d96f5e4c0
Solves __lll_timedlock_wait busy-wait issues described at
http://sourceware.org/bugzilla/show_bug.cgi?id=15119
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
unlocked NORMAL mutex.
Althought, it is undefined behavior, there is no reason for segfault.
Program received signal SIGSEGV, Segmentation fault.
__pthread_unlock (lock=lock@entry=0x804b03c <lock+16>)
at libpthread/linuxthreads.old/spinlock.c:231
231 (&lock->__status, oldstatus, (long)(thr->p_nextlock) & ~1L))
It occurs only on platforms which has HAS_COMPARE_AND_SWAP defined.
Restore glibc commit fbaf6e72d6 "spinlock.c (__pthread_unlock): Don't crash if
called for an untaken mutex." behavior, broken later by commit 4ad1d0cfbf.
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Sync pthread_spin_lock/pthread_spin_trylock with GNU libc as it avoids
any usage of deprecated SWP instruction. This allows to build uClibc-ng
for ARMv8 Cortex-A53 CPU in 32 Bit mode.
|
|
Accidentally, commit 43ef9c6b3 wasn't taken into account.
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Commit 9c4fce55a (nptl: remove sigaction, sigprocmask, and sigfillset from
libpthread) removed pt-sigaction.c from the build to fix static build.
However, since the libc sigaction is weak when HAS_THREADS is enabled, static
build is not be affected. Tested for xtensa, x86, MIPS32 targets.
Fixes nptl/tst-signal7.
Moreover, commit 9193a76bb from the 0.9.33 branch has the right version.
Ref.: http://patchwork.ozlabs.org/patch/286084/
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Got the working code from https://github.com/jdkoftinoff/mb-linux-msli/,
otherwise SIGILL while using linuxthreads.
|
|
Linuxthreads.new isn't really useful with the existence
of NPTL/TLS for well supported architectures. There is no
reason to use LT.new for ARM/MIPS or other architectures
supporting NPTL/TLS. It is not available for noMMU architectures
like Blackfin or FR-V. To simplify the live of the few uClibc-ng
developers, LT.new is removed and LT.old is renamed to LT.
LINUXTHREADS_OLD -> UCLIBC_HAS_LINUXTHREADS
|
|
copy file from linuxthreads to be able to compile gdbserver.
|
|
License notices in most of the source files refer to an outdated
FSF address. Replace it with URL, like in the rest of the source
files.Signed-off-by: Nikola Forró <nforro@redhat.com>
|
|
|
|
|
|
Currently, the Thumb support on ARM has three related Config.in
options, which are not trivial for users to understand, and are in
fact not needed:
- The USE_BX option is not needed: knowing whether BX is available or
not is easy. If you have an ARM > v4 or ARMv4T, then BX is
available, otherwise it's not. This is the logic used in glibc.
- The USE_LDREXSTREX option is not needed: whenever Thumb2 is
available, ldrex/strex are available, so we can simply rely on
__thumb2__ to determine whether ldrex/strex should be used, without
requiring a Config.in option.
- Once USE_BX and USE_LDREXSTREX are removed, the only thing left
that COMPILE_IN_THUMB does is to set -mthumb. This makes the option
unnecessary, as on ARM at least, the user is already supposed to
pass -march=<foo> or other compiler options tuning the library for
a specific ARM variant. There is no reason to do otherwise for
Thumb, which allows to get rid of the COMPILE_IN_THUMB option.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
|
At least allow to build a toolchain for hppa.
Sync some headers with glibc.
|
|
fix infinite recursion on application exit triggered by linking
libc before libpthread.
Patch from OpenWrt.
Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Trivial fix.
Signed-Off-By: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Some applications needs it.
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Both architectures are more or less deprecated.
No Linux upstream support, no gcc support for uClinux.
|
|
Use the arch specific thread stack size for nptl if the size
returned by getrlimits exceeds it - fixes threads on systems
with only 16 MB RAM.
Patch from OpenWRT
Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Idea from different projects as OpenWrt and others.
https://lists.openwrt.org/pipermail/openwrt-devel/2013-November/022299.html
https://github.com/wl500g/toolchain/blob/master/toolchain/uClibc/patches/0.9.32/980-stack-cache-maxsize.patch
|
|
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
Get rid of NIOS support. We try to support NIOSII.
|