1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
3 * ARM userspace implementations of gettimeofday() and similar.
4 *
5 * Copyright 2015 Mentor Graphics Corporation.
6 */
7
8 #ifdef CONFIG_RANDOMIZE_BASE
9 #pragma GCC visibility pop
10 #endif
11
12 #include <linux/time.h>
13 #include <linux/types.h>
14
__vdso_clock_gettime(clockid_t clock,struct old_timespec32 * ts)15 int __vdso_clock_gettime(clockid_t clock,
16 struct old_timespec32 *ts)
17 {
18 return __cvdso_clock_gettime32(clock, ts);
19 }
20
__vdso_clock_gettime64(clockid_t clock,struct __kernel_timespec * ts)21 int __vdso_clock_gettime64(clockid_t clock,
22 struct __kernel_timespec *ts)
23 {
24 return __cvdso_clock_gettime(clock, ts);
25 }
26
__vdso_gettimeofday(struct __kernel_old_timeval * tv,struct timezone * tz)27 int __vdso_gettimeofday(struct __kernel_old_timeval *tv,
28 struct timezone *tz)
29 {
30 return __cvdso_gettimeofday(tv, tz);
31 }
32
__vdso_clock_getres(clockid_t clock_id,struct old_timespec32 * res)33 int __vdso_clock_getres(clockid_t clock_id,
34 struct old_timespec32 *res)
35 {
36 return __cvdso_clock_getres_time32(clock_id, res);
37 }
38
39 /* Avoid unresolved references emitted by GCC */
40
__aeabi_unwind_cpp_pr0(void)41 void __aeabi_unwind_cpp_pr0(void)
42 {
43 }
44
__aeabi_unwind_cpp_pr1(void)45 void __aeabi_unwind_cpp_pr1(void)
46 {
47 }
48
__aeabi_unwind_cpp_pr2(void)49 void __aeabi_unwind_cpp_pr2(void)
50 {
51 }
52