xref: /linux/arch/arm64/kernel/vdso32/vgettimeofday.c (revision 7192ad2a)
1a7f71a2cSVincenzo Frascino // SPDX-License-Identifier: GPL-2.0
2a7f71a2cSVincenzo Frascino /*
3a7f71a2cSVincenzo Frascino  * ARM64 compat userspace implementations of gettimeofday() and similar.
4a7f71a2cSVincenzo Frascino  *
5a7f71a2cSVincenzo Frascino  * Copyright (C) 2018 ARM Limited
6a7f71a2cSVincenzo Frascino  *
7a7f71a2cSVincenzo Frascino  */
8*7192ad2aSNathan Chancellor #define BUILD_VDSO32_64
942874e4eSArnd Bergmann #include <vdso/gettime.h>
10a7f71a2cSVincenzo Frascino 
__vdso_clock_gettime(clockid_t clock,struct old_timespec32 * ts)11a7f71a2cSVincenzo Frascino int __vdso_clock_gettime(clockid_t clock,
12a7f71a2cSVincenzo Frascino 			 struct old_timespec32 *ts)
13a7f71a2cSVincenzo Frascino {
14a7f71a2cSVincenzo Frascino 	return __cvdso_clock_gettime32(clock, ts);
15a7f71a2cSVincenzo Frascino }
16a7f71a2cSVincenzo Frascino 
__vdso_clock_gettime64(clockid_t clock,struct __kernel_timespec * ts)17a7f71a2cSVincenzo Frascino int __vdso_clock_gettime64(clockid_t clock,
18a7f71a2cSVincenzo Frascino 			   struct __kernel_timespec *ts)
19a7f71a2cSVincenzo Frascino {
20a7f71a2cSVincenzo Frascino 	return __cvdso_clock_gettime(clock, ts);
21a7f71a2cSVincenzo Frascino }
22a7f71a2cSVincenzo Frascino 
__vdso_gettimeofday(struct __kernel_old_timeval * tv,struct timezone * tz)23a7f71a2cSVincenzo Frascino int __vdso_gettimeofday(struct __kernel_old_timeval *tv,
24a7f71a2cSVincenzo Frascino 			struct timezone *tz)
25a7f71a2cSVincenzo Frascino {
26a7f71a2cSVincenzo Frascino 	return __cvdso_gettimeofday(tv, tz);
27a7f71a2cSVincenzo Frascino }
28a7f71a2cSVincenzo Frascino 
__vdso_clock_getres(clockid_t clock_id,struct old_timespec32 * res)29a7f71a2cSVincenzo Frascino int __vdso_clock_getres(clockid_t clock_id,
30a7f71a2cSVincenzo Frascino 			struct old_timespec32 *res)
31a7f71a2cSVincenzo Frascino {
32a7f71a2cSVincenzo Frascino 	return __cvdso_clock_getres_time32(clock_id, res);
33a7f71a2cSVincenzo Frascino }
34a7f71a2cSVincenzo Frascino 
35a7f71a2cSVincenzo Frascino /* Avoid unresolved references emitted by GCC */
36a7f71a2cSVincenzo Frascino 
__aeabi_unwind_cpp_pr0(void)37a7f71a2cSVincenzo Frascino void __aeabi_unwind_cpp_pr0(void)
38a7f71a2cSVincenzo Frascino {
39a7f71a2cSVincenzo Frascino }
40a7f71a2cSVincenzo Frascino 
__aeabi_unwind_cpp_pr1(void)41a7f71a2cSVincenzo Frascino void __aeabi_unwind_cpp_pr1(void)
42a7f71a2cSVincenzo Frascino {
43a7f71a2cSVincenzo Frascino }
44a7f71a2cSVincenzo Frascino 
__aeabi_unwind_cpp_pr2(void)45a7f71a2cSVincenzo Frascino void __aeabi_unwind_cpp_pr2(void)
46a7f71a2cSVincenzo Frascino {
47a7f71a2cSVincenzo Frascino }
48