x86_64: Fix get_tls and statvfs
* bionic_tls.h - Add x86_64 version of get_tls macro;
* statvfs.h - 64-bit kernels don't have __statfs64/__fstatfs64, applying
workaround;
Change-Id: I20d7ddad74c7b7243866373d0142da6627c08280
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
diff --git a/libc/private/bionic_tls.h b/libc/private/bionic_tls.h
index 9ea3647..f7a9051 100644
--- a/libc/private/bionic_tls.h
+++ b/libc/private/bionic_tls.h
@@ -106,6 +106,12 @@
({ register void* __val; \
asm ("movl %%gs:0, %0" : "=r"(__val)); \
(volatile void*) __val; })
+
+#elif defined(__x86_64__)
+# define __get_tls() \
+ ({ register void* __val; \
+ asm ("mov %%fs:0, %0" : "=r"(__val)); \
+ (volatile void*) __val; })
#else
#error unsupported architecture
#endif