OSDN Git Service
Khem Raj [Mon, 25 Jan 2010 23:17:09 +0000 (15:17 -0800)]
Makefile.arch: On ARM and MIPS pass -DNOT_IN_libc=1 -DIS_IN_libpthread=1
* This will prevent it using internal __libc* symbols in pthread which
should be hidden for libc only use.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Khem Raj [Mon, 25 Jan 2010 22:42:00 +0000 (14:42 -0800)]
mips/dl-tls.h: Adjust TLS_TPREL_VALUE and TLS_DTPREL_VALUE
* Symbol values are passed in directly into these macros
instead of the symbol structure.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Khem Raj [Mon, 25 Jan 2010 22:24:26 +0000 (14:24 -0800)]
mips/ldso: Check for TLS relocation in elf_machine_type_class.
* Store the symbol adress received from _dl_find_hash
and do not recompute it.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Carmelo Amoroso [Mon, 25 Jan 2010 05:12:08 +0000 (06:12 +0100)]
Merge branch 'master' into nptl
Conflicts:
libc/inet/Makefile.in
libc/inet/hostid.c
Synchronise nptl branch with master branch @
c4b750195714ec7c10aa4de15610c5aae0751c1c
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Henning Heinold [Sun, 24 Jan 2010 05:29:42 +0000 (21:29 -0800)]
Makefile.in: Make install_dev depend on install_runtime.
* Helps in parallel build.
Signed-off-by: Henning Heinold <heinold@inf.fu-berlin.de>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Denys Vlasenko [Sun, 24 Jan 2010 01:26:26 +0000 (02:26 +0100)]
wchar.c: fix indentation
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 23:39:57 +0000 (00:39 +0100)]
gethostid: switch to getaddrinfo and shrink
text data bss dec hex filename
382 0 0 382 17e libc/inet/hostid.os.old
326 0 0 326 146 libc/inet/hostid.os
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 22:25:01 +0000 (23:25 +0100)]
getprotoent_r: use correct define for return value
Doesn't correctly set result=NULL on error or EOF.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 21:41:25 +0000 (22:41 +0100)]
fix typo in previous commit
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 21:37:01 +0000 (22:37 +0100)]
silence some warnings about unused params
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 21:36:27 +0000 (22:36 +0100)]
ftw.h installation: fix inverted logic
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 20:29:19 +0000 (21:29 +0100)]
libc/inet: mark other odd /etc/conf/ spot
and wrap it in FALLBACK_TO_CONFIG_RESOLVCONF too. -24b
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 20:22:32 +0000 (21:22 +0100)]
libc/inet: set path to resolver file via CPP
No objcode changes.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 23 Jan 2010 20:11:47 +0000 (21:11 +0100)]
libc/inet: convert to foo-y kbuild style
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Austin Foxley [Sat, 23 Jan 2010 17:47:03 +0000 (09:47 -0800)]
nptl: timer_routines.c (timer_helper_thread):
Use sigfillset. Document that sigfillset does the right thing wrt
to SIGSETXID.
Sync with glibc
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Sat, 23 Jan 2010 17:31:05 +0000 (09:31 -0800)]
test: fix static build of nptl and tls tests
also add needed -lpthread lines to timer_* tests,
since the implementation uses pthread functions
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Sat, 23 Jan 2010 17:29:29 +0000 (09:29 -0800)]
nptl: need to build generic timer_* functions for x86_64 and sparc
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Sat, 23 Jan 2010 17:26:48 +0000 (09:26 -0800)]
nptl: fix a few more old style prototypes
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Bernhard Reutner-Fischer [Fri, 22 Jan 2010 12:57:32 +0000 (13:57 +0100)]
silence warning about implicit decl of sysctl
... and reinstate comment explaining the gory details
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Thu, 21 Jan 2010 09:42:02 +0000 (10:42 +0100)]
wordexp: silence shadow warning
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
831ea78623556cbfae002477afc6256cacaaf2c6)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Thu, 21 Jan 2010 09:36:13 +0000 (10:36 +0100)]
fix typo in version mismatch msg
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
0d30e6a7666c3cab001e7343a71bfa2d3e5abbd4)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:33:14 +0000 (17:33 +0100)]
ldso: tweak shadow warning with preload file support
The stat buffer is already declared at the top of the function.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
6140a2a7175a796a7c06119f036357db87a1b865)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:26:11 +0000 (17:26 +0100)]
rename exp(onent) to _exp
to avoid shadow warnings
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
2b12ef1e789227cf9425ae8645e62ba7c3a7d3a9)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:21:52 +0000 (17:21 +0100)]
ether_line: fix build for socket && !ip
The internal __ether_line helper needs ether_ntoa_r()
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
81264e8097b705f3b2a7e29be0a1a2ea853230cb)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Wed, 20 Jan 2010 22:42:57 +0000 (23:42 +0100)]
test commit
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
1571ed1315ff95278fed019b838f183ee37cc198)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Sat, 16 Jan 2010 18:18:38 +0000 (19:18 +0100)]
futimens: add missing local prototype
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
d0a8b14169c6f01dadd07f6b4e14cc335a62f234)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Sat, 16 Jan 2010 18:14:12 +0000 (19:14 +0100)]
rename exp(onent) to ex
to avoid shadow warnings
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
f331f6d2eff5fb623bcc42213ccec12c7dbf95fd)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Bernhard Reutner-Fischer [Fri, 15 Jan 2010 14:59:56 +0000 (15:59 +0100)]
randconfig.sh: set number of make jobs
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
c13dd47ecbbdb841042e1370c8011e84634db0e4)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Yoshinori Sato [Sat, 16 Jan 2010 18:14:29 +0000 (19:14 +0100)]
include unistd.h for smallint
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
(cherry picked from commit
df9130a0dc1c9e3553fcfee68bb8a809e4f4a458)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Khem Raj [Wed, 13 Jan 2010 01:51:32 +0000 (17:51 -0800)]
mips/nptl: Pass correct parameters to dl_find_hash when resolving TLS relocations.
Make use of macros from sys/asm.h in crt1.S
These two changes are needed for mips nptl to boot once again.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
(cherry picked from commit
9c343fd4030dcd7a52616f365893177dded50346)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Denys Vlasenko [Sat, 9 Jan 2010 20:58:50 +0000 (21:58 +0100)]
ctime: do not use static struct tm buffer
text data bss dec hex filename
- 19 0 0 19 13 libc/misc/time/ctime.o
+ 25 0 0 25 19 libc/misc/time/ctime.o
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
(cherry picked from commit
957e238614326198452b53498ae98e546fce7366)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Sun, 27 Dec 2009 20:13:52 +0000 (12:13 -0800)]
test/math: put scalbf test under susv3 legacy define
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
(cherry picked from commit
e949d522a31db675889bc87b6023e7edb6b30caa)
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Hans-Christian Egtvedt [Wed, 16 Dec 2009 12:16:08 +0000 (13:16 +0100)]
avr32: add varargs handling of prctl syscall
prctl is defined to use varargs in the header file, hence it needs varargs
specific handling in the source. This patch properly handles the variodic
argument before the syscall is passed to the kernel for the AVR32 architecture.
Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Hans-Christian Egtvedt [Wed, 16 Dec 2009 12:16:08 +0000 (13:16 +0100)]
avr32: add varargs handling of prctl syscall
prctl is defined to use varargs in the header file, hence it needs varargs
specific handling in the source. This patch properly handles the variodic
argument before the syscall is passed to the kernel for the AVR32 architecture.
Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Bernhard Reutner-Fischer [Thu, 21 Jan 2010 09:42:02 +0000 (10:42 +0100)]
wordexp: silence shadow warning
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Thu, 21 Jan 2010 09:36:13 +0000 (10:36 +0100)]
fix typo in version mismatch msg
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:33:14 +0000 (17:33 +0100)]
ldso: tweak shadow warning with preload file support
The stat buffer is already declared at the top of the function.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:26:11 +0000 (17:26 +0100)]
rename exp(onent) to _exp
to avoid shadow warnings
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Tue, 19 Jan 2010 16:21:52 +0000 (17:21 +0100)]
ether_line: fix build for socket && !ip
The internal __ether_line helper needs ether_ntoa_r()
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Wed, 20 Jan 2010 22:42:57 +0000 (23:42 +0100)]
test commit
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 16 Jan 2010 18:18:38 +0000 (19:18 +0100)]
futimens: add missing local prototype
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Sat, 16 Jan 2010 18:14:12 +0000 (19:14 +0100)]
rename exp(onent) to ex
to avoid shadow warnings
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Bernhard Reutner-Fischer [Fri, 15 Jan 2010 14:59:56 +0000 (15:59 +0100)]
randconfig.sh: set number of make jobs
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Yoshinori Sato [Sat, 16 Jan 2010 18:14:29 +0000 (19:14 +0100)]
include unistd.h for smallint
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Khem Raj [Wed, 13 Jan 2010 01:51:32 +0000 (17:51 -0800)]
mips/nptl: Pass correct parameters to dl_find_hash when resolving TLS relocations.
Make use of macros from sys/asm.h in crt1.S
These two changes are needed for mips nptl to boot once again.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Denys Vlasenko [Sat, 9 Jan 2010 20:58:50 +0000 (21:58 +0100)]
ctime: do not use static struct tm buffer
text data bss dec hex filename
- 19 0 0 19 13 libc/misc/time/ctime.o
+ 25 0 0 25 19 libc/misc/time/ctime.o
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Austin Foxley [Sun, 27 Dec 2009 20:13:52 +0000 (12:13 -0800)]
test/math: put scalbf test under susv3 legacy define
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Wed, 23 Dec 2009 20:14:26 +0000 (12:14 -0800)]
Merge remote branch 'origin/master' into nptl
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Chris Metcalf [Wed, 23 Dec 2009 20:00:55 +0000 (15:00 -0500)]
Make _dl_dprintf buf non-static to avoid multithreading bugs.
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Sat, 19 Dec 2009 22:02:14 +0000 (14:02 -0800)]
Merge commit 'origin/master' into nptl
Conflicts:
libc/signal/sigpause.c
libc/string/x86_64/memset.S
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Freeman Wang [Sat, 19 Dec 2009 21:43:00 +0000 (13:43 -0800)]
malloc: fix race condition and other bugs in the no-mmu malloc
Fixes multiple race conditions on mmb list. This was done by
making the mmb_heap_lock into a recursive lock and making the
regular heap_lock extend to cover the mmb heap handling.
Also move the new_mmb allocation up to before the mmb list is
iterated through to find the insertion point. When the mmb_heap
also runs out and needs to be extended when the regular heap is
just extended, the mmb list could be messed up.
Signed-off-by: Freeman Wang <xwang@ubicom.com>
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Sat, 19 Dec 2009 21:35:52 +0000 (13:35 -0800)]
x86_64: fix multiple definition of chk functions
also enable __chk_fail and only try to call it when SSP is on
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Hans-Christian Egtvedt [Wed, 16 Dec 2009 12:12:00 +0000 (13:12 +0100)]
check if USE_TLS is defined before use
This patch will convert all the #ifdef USE_TLS and #if USE_TLS to
#if defined(USE_TLS) && USE_TLS.
By checking if the USE_TLS is defined before checking its value will result in
correct behavior for architectures not defining this config symbol.
Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Acked-by: Carmelo AMOROSO <carmelo.amoroso@st.com>
Hans-Christian Egtvedt [Wed, 16 Dec 2009 12:12:00 +0000 (13:12 +0100)]
check if USE_TLS is defined before use
This patch will convert all the #ifdef USE_TLS and #if USE_TLS to
#if defined(USE_TLS) && USE_TLS.
By checking if the USE_TLS is defined before checking its value will result in
correct behavior for architectures not defining this config symbol.
Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Acked-by: Carmelo AMOROSO <carmelo.amoroso@st.com>
Austin Foxley [Wed, 16 Dec 2009 11:43:50 +0000 (03:43 -0800)]
x86_64: fix up the rest of the includes and aliases for nptl
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Carmelo Amoroso [Wed, 16 Dec 2009 11:37:07 +0000 (12:37 +0100)]
libc: Remove pointless header string.h
It is already include from the internal header sigset-cvt-mask.h
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Wed, 16 Dec 2009 11:07:43 +0000 (12:07 +0100)]
libc: Add missing header for memset
Silence compiler warning by adding the missing string.h header
to include memset prototype.
Do some code tidy-up removing commented out libc_hidden_proto macros
in the meanwhile.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Wed, 16 Dec 2009 11:05:38 +0000 (03:05 -0800)]
x86_64: add missing includes to sem_*.S
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Carmelo Amoroso [Wed, 16 Dec 2009 08:17:45 +0000 (09:17 +0100)]
libc: Add missing header for memset
Silence compiler warning by adding the missing string.h header
to include memset prototype.
Do some code tidy-up removing commented out libc_hidden_proto macros
in the meanwhile.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Wed, 16 Dec 2009 10:52:30 +0000 (02:52 -0800)]
fix multiple definitions of pthread_once for x86_64
also add a missing weak for clone
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Wed, 16 Dec 2009 10:36:31 +0000 (02:36 -0800)]
fix compiling test cases in static mode
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Wed, 16 Dec 2009 10:29:42 +0000 (02:29 -0800)]
x86_64: no waitpid syscall exists, so use wait4
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Carmelo Amoroso [Wed, 16 Dec 2009 08:13:52 +0000 (09:13 +0100)]
build: Do not define -DPIC longer through build system
Now all code relies upon __PIC__ flag defined by compiler, so
it does not need to explicitly define the PIC macro through build system
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Wed, 16 Dec 2009 08:09:38 +0000 (09:09 +0100)]
build: Get rids of PIC macro using compiler flag __PIC__ instead
Based on Peter Mazinger's comments on a recent commit, I decided
to get rids of all occurrences of PIC changing them to __PIC__
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Wed, 16 Dec 2009 07:48:08 +0000 (08:48 +0100)]
build: Get rids of PIC macro using compiler flag __PIC__ instead
Based on Peter Mazinger's comments on a recent commit, I decided
to get rids of all occurrences of PIC changing them to __PIC__
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Wed, 16 Dec 2009 03:19:39 +0000 (19:19 -0800)]
Merge remote branch 'origin/master' into nptl
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Natanael Copa [Tue, 15 Dec 2009 12:37:34 +0000 (12:37 +0000)]
fix typo that sneaked in with 9a7506
Signed-off-by: Natanael Copa <natanael.copa@gmail.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Giuseppe Cavallaro [Mon, 14 Dec 2009 15:45:49 +0000 (16:45 +0100)]
sh: fix endianess and optimise the SH4 memcpy
This patch fixes the big-endian code and adds a new optimization
only for little endian mode.
This optimization is based on prefetching and 64bit data transfer via FPU.
Tests shows that
----------------------------------------
Memory bandwidth | Gain
| sh4-300 | sh4-200
----------------------------------------
512 bytes to 16KiB | ~20% | ~25%
from 32KiB to 16MiB | ~190% | ~5%
----------------------------------------
Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Denys Vlasenko [Sun, 13 Dec 2009 04:47:19 +0000 (05:47 +0100)]
syslog: use send(MSG_NOSIGNAL) instead of write, thus no need to handle SIGPIPE
Size changes by this and previous change:
text data bss dec hex filename
1151 13 2 1166 48e libc/misc/syslog/syslog.o
1093 10 2 1105 451 libc/misc/syslog/syslog.o
1047 10 2 1059 423 libc/misc/syslog/syslog.o
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Denys Vlasenko [Sun, 13 Dec 2009 03:00:52 +0000 (04:00 +0100)]
syslog: fix openlog(xx, LOG_KERN) and optimize a bit
The fix:
logfac == 0 in openlog(xx, logfac) is allowed now.
Corresponding internal openlog() call in vsyslog()
uses explicit LOG_USER in order to set it as a default
facility.
Optimizations:
mylock is not recursive now, since a single intenal call
of openlog is converted to a call to openlog_internal
which assumes that lock is already taken. No recursive
locking is possible now.
LogFacility is reduced to byte.
cache static LogFile in auto variable fd (smaller code).
vsyslog with bogus pri parameter wouldn't lock/unlock
and mess with signals - it will just return at once.
pass NULL as ident string in internal openlog call
- same effect as passing LogTag but smaller code.
comment out "if (LogTag)" checks - it is never NULL.
use the same struct sigaction for setting new sigaction
and for saving old one - saves ~32 bytes of stack.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Khem Raj [Fri, 11 Dec 2009 17:40:05 +0000 (09:40 -0800)]
Include bits/libc-lock.h to get __libc_once_define
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Fri, 11 Dec 2009 18:10:40 +0000 (10:10 -0800)]
Go back to using nptl_arch_headers
this is part of the revert of
641e7e36ad0a9
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Fri, 11 Dec 2009 18:05:57 +0000 (10:05 -0800)]
Revert "nptl: make build depend directly on nptl headers"
This reverts commit
641e7e36ad0a9b2899b04f256c5b243ada7da279.
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Khem Raj [Fri, 11 Dec 2009 17:40:05 +0000 (09:40 -0800)]
Include bits/libc-lock.h to get __libc_once_define
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Acked-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Fri, 11 Dec 2009 11:46:37 +0000 (03:46 -0800)]
get x86_64 nptl building
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Fri, 11 Dec 2009 08:51:06 +0000 (00:51 -0800)]
nptl: fix even more old style declarations
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Thu, 10 Dec 2009 02:10:53 +0000 (18:10 -0800)]
nptl: fix a few more old style declerations
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Thu, 10 Dec 2009 00:53:57 +0000 (16:53 -0800)]
nptl: fix old style function declerations
also fix a few shadowed local warnings
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Wed, 9 Dec 2009 22:51:45 +0000 (14:51 -0800)]
nptl: make build depend directly on nptl headers
gets rid of nptl_headers,nptl_arch_headers,nptl_linux_headers targets
also, clean up extra slashes in i386/sparc and unify the implementation
of nptl header generation between all archs
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Bernhard Reutner-Fischer [Wed, 9 Dec 2009 20:12:37 +0000 (21:12 +0100)]
warn about old-style crap in extra-annoyance-mode
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Filippo Arcidiacono [Wed, 9 Dec 2009 15:24:46 +0000 (16:24 +0100)]
test_dlopen: Remove extra -lpthread from LD_FLAGS for dltest{2}
dltest and dltest2 do not refer any symbols implemented
in pthread library, so do not explicitly link them with pthread.
It is required only for the shared objects that are loaded
via dlopen by those tests.
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Filippo Arcidiacono [Wed, 9 Dec 2009 15:24:46 +0000 (16:24 +0100)]
test_dlopen: Remove extra -lpthread from LD_FLAGS for dltest{2}
dltest and dltest2 do not refer any symbols implemented
in pthread library, so do not explicitly link them with pthread.
It is required only for the shared objects that are loaded
via dlopen by those tests.
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Fri, 4 Dec 2009 22:32:10 +0000 (14:32 -0800)]
i386 nptl: add missing weak_alias for pthread_cond_signal
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Carmelo Amoroso [Thu, 3 Dec 2009 12:33:16 +0000 (13:33 +0100)]
ldso_tls: Refetch dtv from memory if THREAD_DTV has changed
_dl_update_slotinfo might change THREAD_DTV () (if it needs to reallocate it),
but the caller (__tls_get_addr) doesn't refetch dtv from memory, it uses its
cached copy. This may crash (if dtv[GET_ADDR_MODULE] is off the cliff, or
might read uninitialized memory and return it.
Typically dtv[GET_ADDR_MODULE].pointer.val is NULL and so __tls_get_addr
returns NULL + offset_within_PT_TLS. The next time __tls_get_addr is called
for the same library it will return correct address as _dl_update_slotinfo
won't need to be called.
Signed-off-by: Jakub Jelinek <jakub@redhat.com>
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Thu, 3 Dec 2009 12:29:53 +0000 (13:29 +0100)]
test_tls: Add two new tests for tls tst-tls{16,17} taken from glibc
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Thu, 3 Dec 2009 12:07:54 +0000 (13:07 +0100)]
test_tls: Rename tst-tls16 to tst-tls-at-ctor
Rename tst-tls16 to tst-tls-at-ctor (including main and related
shared object) to avoid name clashing with new tests ported from
glibc.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Thu, 3 Dec 2009 11:21:54 +0000 (12:21 +0100)]
build: Move test build flags in Makefile.in
Move test build flags in Makefile.in
Makefile should be used only as a container for other sub Makefiles
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Thu, 3 Dec 2009 07:06:10 +0000 (08:06 +0100)]
sh: Add a prototype for the gcc __set_fpscr internal function
The sh port uses the gcc __set_fpscr internal function, but neither gcc
nor glibc creates a prototype for it. This leads to a bunch of random
warnings about implicit decls during the build.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Carmelo Amoroso [Thu, 3 Dec 2009 07:06:10 +0000 (08:06 +0100)]
sh: Add a prototype for the gcc __set_fpscr internal function
The sh port uses the gcc __set_fpscr internal function, but neither gcc
nor glibc creates a prototype for it. This leads to a bunch of random
warnings about implicit decls during the build.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Austin Foxley [Tue, 1 Dec 2009 04:43:56 +0000 (20:43 -0800)]
uClibc_ctype.h: fix inverted check for susv4 macro
Was causing build failures if ctype tables were disabled and susv4 was on
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Tue, 1 Dec 2009 04:43:56 +0000 (20:43 -0800)]
uClibc_ctype.h: fix inverted check for susv4 macro
Was causing build failures if ctype tables were disabled and susv4 was on
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 20:11:40 +0000 (12:11 -0800)]
getaddrinfo.c: include tls.h before resolv.h
This is needed because tls.h ends up includeing nptl/descr.h
which needs the full res_state definition. resolv.h also ends up
including tls.h, but _without_ the full res_state struct it errors.
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 04:59:41 +0000 (20:59 -0800)]
test/.gitignore: ignore a missed nptl test binary
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 04:54:10 +0000 (20:54 -0800)]
test/.gitignore: Ignore a few more test binaries
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 04:54:10 +0000 (20:54 -0800)]
test/.gitignore: Ignore a few more test binaries
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 04:48:59 +0000 (20:48 -0800)]
test/Rules.mak: disable -z,defs for now
* A bunch of the nptl tests don't compile when -z,defs is on
* also turn on -std=gnu99 for the HOSTCC (_glibc) compiles
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 04:18:05 +0000 (20:18 -0800)]
test/nptl: rework tst-tls3 to link with -z,now
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 03:37:13 +0000 (19:37 -0800)]
test/: compile fixes for nptl and tls tests
* Add a GLIBC_TESTS_DISABLED var because many of these tests
need internal uClibc stuff. This disables the HOSTCC build of
these tests
* Fix up tls test macros for x86
* Fix the linking of the tls tests
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 02:23:20 +0000 (18:23 -0800)]
test/nptl: don't use c99 features if you don't need to
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley [Mon, 30 Nov 2009 02:08:17 +0000 (18:08 -0800)]
test: nptl and tls tests need main include dir
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>