This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [RFC v2 03/20] y2038: linux: Provide __clock_settime64 implementation
- From: Arnd Bergmann <arnd at arndb dot de>
- To: Alistair Francis <alistair dot francis at wdc dot com>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, Adhemerval Zanella <adhemerval dot zanella at linaro dot org>, Florian Weimer <fweimer at redhat dot com>, Palmer Dabbelt <palmer at sifive dot com>, macro at wdc dot com, Zong Li <zongbox at gmail dot com>, Zong Li <zong at andestech dot com>, Alistair Francis <alistair23 at gmail dot com>
- Date: Tue, 25 Jun 2019 13:05:20 +0200
- Subject: Re: [RFC v2 03/20] y2038: linux: Provide __clock_settime64 implementation
- References: <cover.1561421042.git.alistair.francis@wdc.com> <4a1304510a5c9b5c2f6432bfdc5c9fd1740a081f.1561421042.git.alistair.francis@wdc.com>
On Tue, Jun 25, 2019 at 2:11 AM Alistair Francis
<alistair.francis@wdc.com> wrote:
> weak_alias (__clock_settime, clock_settime)
> +
> +#if __TIMESIZE != 64
> +int
> +__clock_settime (clockid_t clock_id, const struct timespec *tp)
> +{
> + struct __timespec64 ts64;
> +
> + valid_timespec_to_timespec64 (tp, &ts64);
> + return __clock_settime64 (clock_id, &ts64);
> +}
> +#endif
I missed this when Lukasz first posted this, but I would still
prefer this to be changed.
Having clock_settime() (using the weak_alias) call into
__clock_settime64() means that a kernel that warns about
old user space calling into the old syscall never notices this.
Can you please leave the existing clock_settime()
untouched and instead just change the internal callers
(if any) over to __clock_settime64?
Arnd