Skip to content

Commit 693737b

Browse files
committed
y2038: make ns_to_compat_timeval use __kernel_old_timeval
This gets us one step closer to removing 'struct timeval' from the kernel. We still keep __kernel_old_timeval for interfaces that we cannot fix otherwise, and ns_to_compat_timeval() is provably safe for interfaces that are legitimate users of __kernel_old_timeval on native kernels, so this is an obvious change. Signed-off-by: Arnd Bergmann <[email protected]>
1 parent df1b4ba commit 693737b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

include/linux/compat.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -937,10 +937,10 @@ static inline bool in_compat_syscall(void) { return is_compat_task(); }
937937
*/
938938
static inline struct old_timeval32 ns_to_old_timeval32(s64 nsec)
939939
{
940-
struct timeval tv;
940+
struct __kernel_old_timeval tv;
941941
struct old_timeval32 ctv;
942942

943-
tv = ns_to_timeval(nsec);
943+
tv = ns_to_kernel_old_timeval(nsec);
944944
ctv.tv_sec = tv.tv_sec;
945945
ctv.tv_usec = tv.tv_usec;
946946

0 commit comments

Comments
 (0)