Re: [Y2038] [PATCH 21/23] y2038: itimer: change implementation to timespec64

2019-11-21 Thread Ben Hutchings
On Fri, 2019-11-08 at 22:12 +0100, Arnd Bergmann wrote: [...] > @@ -292,8 +296,8 @@ static unsigned int alarm_setitimer(unsigned int seconds) >* We can't return 0 if we have an alarm pending ... And we'd >* better return too much than too little anyway >*/ > - if

Re: [Y2038] [PATCH 07/23] y2038: vdso: powerpc: avoid timespec references

2019-11-21 Thread Christophe Leroy
Arnd Bergmann a écrit : On Wed, Nov 20, 2019 at 11:43 PM Ben Hutchings wrote: On Fri, 2019-11-08 at 22:07 +0100, Arnd Bergmann wrote: [...] > --- a/arch/powerpc/kernel/vdso32/gettimeofday.S > +++ b/arch/powerpc/kernel/vdso32/gettimeofday.S > @@ -15,10 +15,8 @@ > /* Offset for the low

Re: [Y2038] [PATCH 6/8] lp: fix sparc64 LPSETTIMEOUT ioctl

2019-11-21 Thread Ben Hutchings
On Thu, 2019-11-21 at 15:04 +0100, Arnd Bergmann wrote: [...] > As Greg has already merged the original patch, and that version works > just as well, I'd probably just leave what I did at first. One benefit is > that in case we decide to kill off sparc64 support before drivers/char/lp.c, > the

Re: [Y2038] [PATCH 3/8] powerpc: fix vdso32 for ppc64le

2019-11-21 Thread Ben Hutchings
On Thu, 2019-11-21 at 11:02 +0100, Arnd Bergmann wrote: > On Wed, Nov 20, 2019 at 10:49 PM Ben Hutchings > wrote: > > On Wed, 2019-11-20 at 20:35 +0100, Arnd Bergmann wrote: > > > On Wed, Nov 20, 2019 at 8:13 PM Ben Hutchings > > > wrote: > > > > On Fri, 2019-11-08 at 21:34 +0100, Arnd Bergmann

Re: [Y2038] [PATCH 08/23] y2038: ipc: remove __kernel_time_t reference from headers

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 11:49 PM Ben Hutchings wrote: > > On Fri, 2019-11-08 at 22:07 +0100, Arnd Bergmann wrote: > [...] > > --- a/arch/x86/include/uapi/asm/sembuf.h > > +++ b/arch/x86/include/uapi/asm/sembuf.h > > @@ -21,9 +21,9 @@ struct semid64_ds { > > unsigned long sem_ctime;

Re: [Y2038] [PATCH 07/23] y2038: vdso: powerpc: avoid timespec references

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 11:43 PM Ben Hutchings wrote: > > On Fri, 2019-11-08 at 22:07 +0100, Arnd Bergmann wrote: > [...] > > --- a/arch/powerpc/kernel/vdso32/gettimeofday.S > > +++ b/arch/powerpc/kernel/vdso32/gettimeofday.S > > @@ -15,10 +15,8 @@ > > /* Offset for the low 32-bit part of a

Re: [Y2038] [PATCH 02/23] y2038: add __kernel_old_timespec and __kernel_old_time_t

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 11:30 PM Ben Hutchings wrote: > > On Fri, 2019-11-08 at 22:07 +0100, Arnd Bergmann wrote: > > The 'struct timespec' definition can no longer be part of the uapi headers > > because it conflicts with a a now incompatible libc definition. Also, > > we really want to remove

Re: [Y2038] [PATCH 7/8] ppdev: fix PPGETTIME/PPSETTIME ioctls

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 8:29 PM Ben Hutchings wrote: > > On Fri, 2019-11-08 at 21:34 +0100, Arnd Bergmann wrote: > > Going through the uses of timeval in the user space API, > > I noticed two bugs in ppdev that were introduced in the y2038 > > conversion: > > > > * The range check was

Re: [Y2038] [PATCH 6/8] lp: fix sparc64 LPSETTIMEOUT ioctl

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 11:10 PM Ben Hutchings wrote: > On Wed, 2019-11-20 at 20:46 +0100, Arnd Bergmann wrote: > > On Wed, Nov 20, 2019 at 8:27 PM Ben Hutchings > > wrote: > > - > > return lp_set_timeout(minor, karg[0], karg[1]); > > } > > > > +static int lp_set_timeout(unsigned int

Re: [Y2038] [PATCH 3/8] powerpc: fix vdso32 for ppc64le

2019-11-21 Thread Arnd Bergmann
On Wed, Nov 20, 2019 at 10:49 PM Ben Hutchings wrote: > On Wed, 2019-11-20 at 20:35 +0100, Arnd Bergmann wrote: > > On Wed, Nov 20, 2019 at 8:13 PM Ben Hutchings > > wrote: > > > On Fri, 2019-11-08 at 21:34 +0100, Arnd Bergmann wrote: > > > > On little-endian 32-bit application running on 64-bit

Re: [Y2038] [PATCH] time: Zerofy padding in __kernel_timespec on 32-bit

2019-11-21 Thread Arnd Bergmann
On Thu, Nov 21, 2019 at 1:03 AM Dmitry Safonov wrote: > > On compat interfaces, the high order bits of nanoseconds should > be zeroed out. This is because the application code or the libc > do not guarantee zeroing of these. If used without zeroing, > kernel might be at risk of using timespec