diff options
author | Petr Vorel <petr.vorel@gmail.com> | 2021-01-13 00:37:58 +0100 |
---|---|---|
committer | Yang Xu <xuyang2018.jy@cn.fujitsu.com> | 2021-01-13 10:49:02 +0800 |
commit | 203ee275cf7fe3e08494e5a2404ea40194ca49f6 (patch) | |
tree | 9c96228eb5881a645c8f87d7ebfb3e15be053463 | |
parent | 7acebec6ac76ebfb071696dbe8536dfb2fde031e (diff) |
Fix struct __kernel_old_timeval redefinition on 64bit sparc
64bit sparc is the only arch which defines struct __kernel_old_timeval
in it's asm/posix_types.h header, thus guard it.
NOTE: previously it was guarded with __kernel_timex, which worked as well.
Fixes: a6607b81b ("syscalls: Don't pass struct timeval to tst_syscall()")
Acked-by: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
-rw-r--r-- | include/tst_timer.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/tst_timer.h b/include/tst_timer.h index d2c3f3cb1..657c0824f 100644 --- a/include/tst_timer.h +++ b/include/tst_timer.h @@ -99,10 +99,12 @@ static inline long long tst_timeval_diff_ms(struct timeval t1, typedef __kernel_long_t __kernel_old_time_t; +#ifndef __kernel_old_timeval struct __kernel_old_timeval { __kernel_old_time_t tv_sec; /* seconds */ __kernel_suseconds_t tv_usec; /* microseconds */ }; +#endif struct __kernel_old_timespec { __kernel_old_time_t tv_sec; /* seconds */ |