Re: [PATCH 00/25] Change time_t and clock_t to 64 bit
From: H. Peter Anvin
Date: Fri May 16 2014 - 19:12:26 EST
On 05/15/2014 01:38 PM, Arnd Bergmann wrote:
>
> For practical purposes in the kernel, we may still want to use 64-bit
> nanoseconds: if we use a 96 bit struct timespec, that would be incompatible
> with the native type on 64-bit kernels, thus complicating the syscall
> emulation layer.
>
> I don't know why timespec on x32 uses 'long tv_nsec', it does seem
> problematic.
struct timespec is specified in POSIX as having type "long" for tv_nsec.
This, as Linus pointed out, is totally braindamaged.
x32 does not follow POSIX (Linus pretty much dictated that), and instead
does the __kernel_suseconds_t to match the native kernel type. The
proposal at some point was to try to push a snseconds_t into POSIX.
-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/