summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@uclibc-ng.org>2015-07-11 10:51:46 +0200
committerWaldemar Brodkorb <wbx@uclibc-ng.org>2015-07-11 10:51:46 +0200
commit23424547146e9fd407af501c154656f0688862af (patch)
tree3b0fa18a2ba448f383b62443095057e4cea60ad9
parent7ad3d87d74dfb9eff68ad1686be400154134a731 (diff)
parent449109519492266410421310ee09ff4a10d7c175 (diff)
Merge branch '1.0' of git+ssh://uclibc-ng.org/git/uclibc-ng into 1.0
-rw-r--r--Makefile.in3
-rw-r--r--libpthread/nptl/sysdeps/arc/tls.h7
-rw-r--r--test/tls/tls-macros.h6
3 files changed, 10 insertions, 6 deletions
diff --git a/Makefile.in b/Makefile.in
index 245649cd0..f432760ea 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -183,11 +183,12 @@ menuconfig-clean-y: HEADERCLEAN_config
headers-y += $(target-headers-sysdep)
headers: $(top_builddir)include/bits/uClibc_config.h | subdirs
+ $(Q)$(if $(UCLIBC_HAS_LOCALE),$(MAKE) -C extra/locale locale_headers)
+
subdirs: $(addprefix $(top_builddir),$(subdirs))
$(pregen-headers-y): $(headers_dep)
pregen: headers $(pregen-headers-y) $(headers_dep)
- $(Q)$(if $(UCLIBC_HAS_LOCALE),$(MAKE) -C extra/locale locale_headers)
$(top_builddir)include/bits/sysnum.h: $(top_srcdir)extra/scripts/gen_bits_syscall_h.sh | $(top_builddir)include/bits
@$(disp_gen)
diff --git a/libpthread/nptl/sysdeps/arc/tls.h b/libpthread/nptl/sysdeps/arc/tls.h
index 63dd11398..4af415a1c 100644
--- a/libpthread/nptl/sysdeps/arc/tls.h
+++ b/libpthread/nptl/sysdeps/arc/tls.h
@@ -104,8 +104,11 @@ typedef struct
operation can cause a failure 'errno' must not be touched. */
# define TLS_INIT_TP(tcbp, secondcall) \
({ \
- __builtin_set_thread_pointer(tcbp); \
- NULL; \
+ long result_var; \
+ __builtin_set_thread_pointer(tcbp); \
+ result_var = INTERNAL_SYSCALL (arc_settls, err, 1, (tcbp)); \
+ INTERNAL_SYSCALL_ERROR_P (result_var, err) \
+ ? "unknown error" : NULL; \
})
/* Return the address of the dtv for the current thread.
diff --git a/test/tls/tls-macros.h b/test/tls/tls-macros.h
index a41aef688..7d8927400 100644
--- a/test/tls/tls-macros.h
+++ b/test/tls/tls-macros.h
@@ -900,9 +900,9 @@ register void *__gp __asm__("$29");
#define TLS_LD(x) \
({ int *__l; \
- __asm__ ("movi a8, " #x "@TLSFUNC\n\t" \
- "movi a10, " #x "@TLSARG\n\t" \
- "callx8.tls a8, " #x "@TLSCALL\n\t" \
+ __asm__ ("movi a8, _TLS_MODULE_BASE_@TLSFUNC\n\t" \
+ "movi a10, _TLS_MODULE_BASE_@TLSARG\n\t" \
+ "callx8.tls a8, _TLS_MODULE_BASE_@TLSCALL\n\t" \
"movi %0, " #x "@TPOFF\n\t" \
"add %0, %0, a10\n\t" \
: "=r" (__l) \