about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ldso/aarch64/tlsdesc.s2
-rw-r--r--src/ldso/dynlink.c1
-rw-r--r--src/ldso/i386/tlsdesc.s2
-rw-r--r--src/ldso/tlsdesc.c3
-rw-r--r--src/ldso/x86_64/tlsdesc.s2
5 files changed, 10 insertions, 0 deletions
diff --git a/src/ldso/aarch64/tlsdesc.s b/src/ldso/aarch64/tlsdesc.s
index 69737b2d..8ed5c267 100644
--- a/src/ldso/aarch64/tlsdesc.s
+++ b/src/ldso/aarch64/tlsdesc.s
@@ -3,6 +3,7 @@
 // 	return a[1];
 // }
 .global __tlsdesc_static
+.hidden __tlsdesc_static
 .type __tlsdesc_static,@function
 __tlsdesc_static:
 	ldr x0,[x0,#8]
@@ -19,6 +20,7 @@ __tlsdesc_static:
 // 	return __tls_get_new(p) - tp;
 // }
 .global __tlsdesc_dynamic
+.hidden __tlsdesc_dynamic
 .type __tlsdesc_dynamic,@function
 __tlsdesc_dynamic:
 	stp x1,x2,[sp,#-32]!
diff --git a/src/ldso/dynlink.c b/src/ldso/dynlink.c
index 9f91a738..ccd526f0 100644
--- a/src/ldso/dynlink.c
+++ b/src/ldso/dynlink.c
@@ -250,6 +250,7 @@ static struct symdef find_sym(struct dso *dso, const char *s, int need_def)
 	return def;
 }
 
+__attribute__((__visibility__("hidden")))
 ptrdiff_t __tlsdesc_static(), __tlsdesc_dynamic();
 
 static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stride)
diff --git a/src/ldso/i386/tlsdesc.s b/src/ldso/i386/tlsdesc.s
index 00a9fc09..4a553bce 100644
--- a/src/ldso/i386/tlsdesc.s
+++ b/src/ldso/i386/tlsdesc.s
@@ -1,5 +1,6 @@
 .text
 .global __tlsdesc_static
+.hidden __tlsdesc_static
 .type __tlsdesc_static,@function
 __tlsdesc_static:
 	mov 4(%eax),%eax
@@ -8,6 +9,7 @@ __tlsdesc_static:
 .hidden __tls_get_new
 
 .global __tlsdesc_dynamic
+.hidden __tlsdesc_dynamic
 .type __tlsdesc_dynamic,@function
 __tlsdesc_dynamic:
 	mov 4(%eax),%eax
diff --git a/src/ldso/tlsdesc.c b/src/ldso/tlsdesc.c
index 031b5b80..4bc654fa 100644
--- a/src/ldso/tlsdesc.c
+++ b/src/ldso/tlsdesc.c
@@ -3,6 +3,9 @@
 #include <stddef.h>
 #include "libc.h"
 
+__attribute__((__visibility__("hidden")))
+ptrdiff_t __tlsdesc_static(), __tlsdesc_dynamic();
+
 ptrdiff_t __tlsdesc_static()
 {
 	return 0;
diff --git a/src/ldso/x86_64/tlsdesc.s b/src/ldso/x86_64/tlsdesc.s
index eb21b9de..8238c3eb 100644
--- a/src/ldso/x86_64/tlsdesc.s
+++ b/src/ldso/x86_64/tlsdesc.s
@@ -1,5 +1,6 @@
 .text
 .global __tlsdesc_static
+.hidden __tlsdesc_static
 .type __tlsdesc_static,@function
 __tlsdesc_static:
 	mov 8(%rax),%rax
@@ -8,6 +9,7 @@ __tlsdesc_static:
 .hidden __tls_get_new
 
 .global __tlsdesc_dynamic
+.hidden __tlsdesc_dynamic
 .type __tlsdesc_dynamic,@function
 __tlsdesc_dynamic:
 	mov 8(%rax),%rax