Age | Commit message (Collapse) | Author |
|
Only mips/x86/x86_64 needs a special version of lowlevellock.h.
No regressions found.
|
|
This is to fix an error after switching to use generic syscalls.
libc/sysdeps/linux/common/syscall.c: In function 'syscall':
libc/sysdeps/linux/common/syscall.c:27:2: warning: implicit
declaration of function 'internal_syscall_ncs6'
[-Wimplicit-function-declaration]
return INLINE_SYSCALL_NCS(sysnum, 6, arg1, arg2, arg3, arg4, arg5,
arg6);
^
Defining these functions as described by Vincent Ren-Wei Chen
<vincentc@andestech.com>
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
Traditionally nds32 has had a generic syscall implementation supporting
varargs.
During an audit it was found that this implementation seems to duplicate
the new common implementation and is no longer needed.
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
Now that the common syscall implementation supports vararg calling
conventions we can safely use it on OpenRISC.
This saves a bit of code in the openrisc implementation.
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
The definition of syscall() in unistd.h is with varargs. Traditionally
the common implementation in uclibc has been with regular arguments.
This patch updates that by using varargs.
This has caused issues on architectures like or1k which have different
calling conventions for varargs and regular arg parameters.
The implementation here is based on an implementation from Joel Stanley
<joel@jms.id.au>. There is a difference that I do not initialize the
stack args with 0 as they are immediately overwritten by va_args.
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
Use __NR_sync_file_range2 for csky sync_file_range function.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
Sync with GNU C library commit:
commit a68ba2f3cd3cbe32c1f31e13c20ed13487727b32
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date: Wed Oct 18 17:26:23 2017 +0100
Fixes issues with binutils version > 2.29.1.
|
|
Newer binutils is creating a section INIT_ARRAY from any .init_array
and .ctors in the code. When ld.so runs initialization functions for
loaded objects with _dl_run_init_array() it crashes on Bfin FDPIC
system. It is trying to execute the function in pthread.c, which is
no longer useful with the combined C library approach.
Gcc -Wl,-M debugging output was very useful to find the reason for
the INIT_ARRAY section.
|
|
|
|
|
|
Port over NPTL/TLS support from GNU C Library.
In the first step only the slower syscall is used for TLS
access. The uClibc-ng testsuite shows 79 errors, so their
is room for bugfixes and improvements.
|
|
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
|
|
Pass the -mcpu and -mhard-float from UCLIBC_EXTRA_CFLAGS instead.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
|
|
Busybox internally calls syscall(2).
- in unistd.h defined something like
int syscall(nr, ....)
- in syscall.c (common) implemented as
int syscall(nr, arg1, arg3, arg3, arg4, arg5, arg6)
This will not work, busybox thinks syscall should have varargs calling
conventions. But it doesnt in the uclibc implementation so no args go through.
Most architectures this will work. But on openrisc varargs are all sent on the
stack. Regular args are passed in registers.
Commit message and idea from Stafford Horne <shorne@gmail.com>.
Signed-off-by: Joel Stanley <joel@jms.id.au>
|
|
|
|
|
|
|
|
|
|
Commit ea38f4d89 (math: add exception handling functionality) adds a
regression so that build configurations that have DO_C99_MATH enabled
and DO_XSI_MATH disabled will not link. This commit moves the files with
the bessel functions from DO_C99_MATH to DO_XSI_MATH. It looks like they
are not even contained in C99.
Signed-off-by: Ronald Wahl <ronald.wahl@raritan.com>
|
|
|
|
Add missing member in struct statfs.
It is used by xfsprogs (f.e. 4.13.1).
Reported-by: Joshua Kinard <kumba@gentoo.org>
|
|
From or1k-glibc from blueCmd, his commit "Fix TLS, removed too much in
rebase".
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
Previously we saved everything, but we only need to save the registers
that are promised to be untouched by the setjmp call.
|
|
|
|
|
|
Follow-up of e3d6c8bffe79b2c070bc7a3aabc9d9c65f6b099e
Signed-off-by: Eugene Rudoy <gene.devel@gmail.com>
Signed-off-by: Ralf Friedl <Ralf.Friedl@online.de>
|
|
|
|
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
It is supported both in the sense of being contained in mips version
of statfs/statfs64 structs and also in the sense that it's filled by
the corresponding kernel syscalls.
It is UNsupported in that sense that it's value is the same as that
of f_bsize (at least on older kernel versions, the oldest version
tested is 2.6.13), s. [1] and [2] for details ([1] is the latest
kernel version as of now, [2] is the oldest kernel version git
history is available for).
[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/tree/fs/statfs.c?h=v4.14-rc7#n64
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/tree/fs/open.c?h=v2.6.12-rc2#n41
Follow-up of 68de9946e914d8c30dcc6667a059ea59e5b74cac
Signed-off-by: Eugene Rudoy <gene.devel@gmail.com>
Signed-off-by: Ralf Friedl <Ralf.Friedl@online.de>
|
|
Fix iteration over signals, synced with GNU C library code and
pending patches. Issues found when running dhcpcd with hook
scripts. (exit status 127)
Reported-By: kapeka <kapeka@bering-uclibc.de>
|
|
Follow the steps to build c-sky uclibc linux system:
1. git clone https://github.com/c-sky/buildroot.git
2. cd buildroot
3. make qemu_csky_ck810_uclibc_defconfig
4. make
Follow the buildroot/board/qemu/csky/readme.txt to run.
This buildroot toolchain is pre-build, But you can rebuild
the c-sky uclibc-ng alone and install it to the buildroot
sysroot manually.
We'll try our best to improve the uclibc-ng continuously.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
For noMMU targets we need a pthread_atfork dummy, otherwise
libraries like libressl using pthread_atfork, but not fork()
for itself, can not be used. But software like curl with
ssl support linking against libressl still work fine on noMMU
targets.
|
|
|
|
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
Signed-off-by: Stafford Horne <shorne@gmail.com>
|
|
|
|
According to standards SVID and SYSV.
Modified lgamma calling in case when 'signgam' variable should not be used.
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
After discussion on the busybox mailinglist.
Reported-by: Ralf Friedl <Ralf.Friedl@online.de>
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
After discussions on the busybox mailinglist.
Reported-by: Ralf Friedl <Ralf.Friedl@online.de>
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
Signed-off-by: Alex Potapenko <opotapenko@gmail.com>
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
sysconf creates a lot of code dependencies.
getpagesize dosen't.
staticly linked code that calls malloc is now much smaller.
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
|
|
As h8/300 architecture does not use deprecated syscalls
after reintroduction into Linux upstream, this part of
the code in vfork.S is always unused.
|
|
warning: unused variable 'self' [-Wunused-variable]
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
|
|
The recvmmsg and sendmmsg is very important for UDP stream application.
If we only use recvmsg for UDP stream, it will only copy one mtu size
of data in a syscall. And recvmmsg copy as many as you want in a syscall.
So recvmmsg is more efficient,and some applications will depends on the
recvmmsg and sendmmsg, eg: UDP media stream player.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
In the test-case of statfs from ltp-testsuite, it pass -1 to 2th
argument. eg: fstatfs(fd , -1)
When uclibc-ng parse the buf32 to buf will cause illegal address
access, the kernel will signal the process with SIGSEGV.
If we pass the -1 directly to the syscall of statfs/fstatfs, kernel
use copy_to_user() to prevent the signal of SIGSEGV and just return
EINVAL.
This is the ltp-testsuite expect.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|
|
The current uclibc-ng use 4 arguments, and this will cause
ltp-testsuite's preadv/pwritev case failed.
The syscall of preadv/pwritev in current linux-kernel is 5 arguments:
linux/fs/read_write.c:
SYSCALL_DEFINE5(preadv, unsigned long, fd, const struct iovec __user *, vec,
unsigned long, vlen, unsigned long, pos_l, unsigned long, pos_h)
SYSCALL_DEFINE5(pwritev, unsigned long, fd, const struct iovec __user *, vec,
unsigned long, vlen, unsigned long, pos_l, unsigned long, pos_h)
So just update to 5-args-syscall, and off_t could be 32bit or 64bit.
Signed-off-by: Guo Ren <ren_guo@c-sky.com>
|