From: Ben Hutchings <ben.hutchings@codethink.co.uk>
To: Arnd Bergmann <arnd@arndb.de>, Richard Henderson <rth@twiddle.net>
Cc: y2038@lists.linaro.org, linux-kernel@vger.kernel.org,
Ivan Kokshaysky <ink@jurassic.park.msu.ru>,
Alexander Viro <viro@zeniv.linux.org.uk>,
linux-alpha@vger.kernel.org, Matt Turner <mattst88@gmail.com>,
Deepa Dinamani <deepa.kernel@gmail.com>
Subject: Re: [Y2038] [PATCH 2/2] alpha: osf_sys.c: use timespec64 where appropriate
Date: Wed, 08 Nov 2017 00:22:39 +0000 [thread overview]
Message-ID: <1510100559.2465.44.camel@codethink.co.uk> (raw)
In-Reply-To: <20171107141029.3160278-2-arnd@arndb.de>
On Tue, 2017-11-07 at 15:09 +0100, Arnd Bergmann wrote:
> Some of the syscall helper functions (do_utimes, poll_select_set_timeout,
> core_sys_select) have changed over the past year or two to use
> 'timespec64' pointers rather than 'timespec'. This was fine on alpha,
> since 64-bit architectures treat the two as the same type.
>
> However, I'd like to change that behavior and make 'timespec64' a proper
> type of its own even on 64-bit architectures, and that will introduce
> harmless type mismatch warnings here.
>
> Also, I'm trying to kill off the do_gettimeofday() helper in favor of
> ktime_get() and related interfaces throughout the kernel.
[...]
> @@ -1004,9 +1013,10 @@ SYSCALL_DEFINE2(osf_gettimeofday, struct timeval32 __user *, tv,
> struct timezone __user *, tz)
> {
> if (tv) {
> - struct timeval ktv;
> - do_gettimeofday(&ktv);
> - if (put_tv32(tv, &ktv))
> + struct timespec64 kts;
> +
> + ktime_get_ts64(&kts);
[...]
But this syscall is supposed to use the realtime clock, no? It seems
like the correct substitute here is getnstimeofday64() (as the kernel-
doc comment for do_gettimeofday() *almost* says).
Ben.
--
Ben Hutchings
Software Developer, Codethink Ltd.
next prev parent reply other threads:[~2017-11-08 0:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-07 14:09 [PATCH 1/2] alpha: osf_sys.c: fix put_tv32 regression Arnd Bergmann
2017-11-07 14:09 ` [PATCH 2/2] alpha: osf_sys.c: use timespec64 where appropriate Arnd Bergmann
2017-11-08 0:22 ` Ben Hutchings [this message]
2017-11-08 14:54 ` [Y2038] " Arnd Bergmann
2017-11-07 15:52 ` [PATCH 1/2] alpha: osf_sys.c: fix put_tv32 regression Al Viro
2017-11-07 16:03 ` Arnd Bergmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1510100559.2465.44.camel@codethink.co.uk \
--to=ben.hutchings@codethink.co.uk \
--cc=arnd@arndb.de \
--cc=deepa.kernel@gmail.com \
--cc=ink@jurassic.park.msu.ru \
--cc=linux-alpha@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mattst88@gmail.com \
--cc=rth@twiddle.net \
--cc=viro@zeniv.linux.org.uk \
--cc=y2038@lists.linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.