MIPS: 32/64-bit VDSO support
File libc/SYSCALLS.TXT is updated to generate bionic's system call wrappers for clock_gettime() & gettimeofday() that will be called if kernel vdso implementations fail to execute. The system call wrappers are generated using a python script gensyscalls.py. Since all architectures support vdso now, there is no more need for conditional statements regarding supported architectures in libc/bionic/vdso.cpp & libc/private/bionic_vdso.h files. Test: builds Change-Id: I7213f29c179a7929851499d78a72900638ae861a Signed-off-by: Goran Ferenc <goran.ferenc@imgtec.com>
This commit is contained in:
parent
15eaaddef9
commit
996f6decfa
|
@ -350,7 +350,5 @@ int __set_tls:set_thread_area(void*) mips,mips64
|
|||
int __set_thread_area:set_thread_area(void*) x86
|
||||
|
||||
# vdso stuff.
|
||||
int clock_gettime(clockid_t, timespec*) mips,mips64
|
||||
int __clock_gettime:clock_gettime(clockid_t, timespec*) arm,arm64,x86,x86_64
|
||||
int gettimeofday(timeval*, timezone*) mips,mips64
|
||||
int __gettimeofday:gettimeofday(timeval*, timezone*) arm,arm64,x86,x86_64
|
||||
int __clock_gettime:clock_gettime(clockid_t, timespec*) all
|
||||
int __gettimeofday:gettimeofday(timeval*, timezone*) all
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <private/bionic_asm.h>
|
||||
|
||||
ENTRY(clock_gettime)
|
||||
ENTRY(__clock_gettime)
|
||||
.set noreorder
|
||||
.cpload t9
|
||||
li v0, __NR_clock_gettime
|
||||
|
@ -16,4 +16,4 @@ ENTRY(clock_gettime)
|
|||
j t9
|
||||
nop
|
||||
.set reorder
|
||||
END(clock_gettime)
|
||||
END(__clock_gettime)
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <private/bionic_asm.h>
|
||||
|
||||
ENTRY(gettimeofday)
|
||||
ENTRY(__gettimeofday)
|
||||
.set noreorder
|
||||
.cpload t9
|
||||
li v0, __NR_gettimeofday
|
||||
|
@ -16,4 +16,4 @@ ENTRY(gettimeofday)
|
|||
j t9
|
||||
nop
|
||||
.set reorder
|
||||
END(gettimeofday)
|
||||
END(__gettimeofday)
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <private/bionic_asm.h>
|
||||
|
||||
ENTRY(clock_gettime)
|
||||
ENTRY(__clock_gettime)
|
||||
.set push
|
||||
.set noreorder
|
||||
li v0, __NR_clock_gettime
|
||||
|
@ -22,4 +22,5 @@ ENTRY(clock_gettime)
|
|||
j t9
|
||||
move ra, t0
|
||||
.set pop
|
||||
END(clock_gettime)
|
||||
END(__clock_gettime)
|
||||
.hidden __clock_gettime
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <private/bionic_asm.h>
|
||||
|
||||
ENTRY(gettimeofday)
|
||||
ENTRY(__gettimeofday)
|
||||
.set push
|
||||
.set noreorder
|
||||
li v0, __NR_gettimeofday
|
||||
|
@ -22,4 +22,5 @@ ENTRY(gettimeofday)
|
|||
j t9
|
||||
move ra, t0
|
||||
.set pop
|
||||
END(gettimeofday)
|
||||
END(__gettimeofday)
|
||||
.hidden __gettimeofday
|
|
@ -17,8 +17,6 @@
|
|||
#include "private/bionic_globals.h"
|
||||
#include "private/bionic_vdso.h"
|
||||
|
||||
#if defined(__aarch64__) || defined(__arm__) || defined(__i386__) || defined(__x86_64__)
|
||||
|
||||
#include <limits.h>
|
||||
#include <link.h>
|
||||
#include <string.h>
|
||||
|
@ -112,10 +110,3 @@ void __libc_init_vdso(libc_globals* globals, KernelArgumentBlock& args) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
void __libc_init_vdso(libc_globals*, KernelArgumentBlock&) {
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
#if defined(__aarch64__)
|
||||
#define VDSO_CLOCK_GETTIME_SYMBOL "__kernel_clock_gettime"
|
||||
#define VDSO_GETTIMEOFDAY_SYMBOL "__kernel_gettimeofday"
|
||||
#elif defined(__arm__) || defined(__i386__) || defined(__x86_64__)
|
||||
#else
|
||||
#define VDSO_CLOCK_GETTIME_SYMBOL "__vdso_clock_gettime"
|
||||
#define VDSO_GETTIMEOFDAY_SYMBOL "__vdso_gettimeofday"
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue