From: Arnd Bergmann <arnd@arndb.de>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: Deepa Dinamani <deepa.kernel@gmail.com>,
John Stultz <john.stultz@linaro.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
y2038 Mailman List <y2038@lists.linaro.org>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Christian Borntraeger <borntraeger@de.ibm.com>,
Catalin Marinas <catalin.marinas@arm.com>,
Chris Metcalf <cmetcalf@mellanox.com>,
cohuck@redhat.com, David Miller <davem@davemloft.net>,
Helge Deller <deller@gmx.de>,
devel@driverdev.osuosl.org, gerald.schaefer@de.ibm.com,
gregkh <gregkh@linuxfoundation.org>,
Heiko Carstens <heiko.carstens@de.ibm.com>,
Jan Hoeppner <hoeppner@linux.vnet.ibm.com>,
"H. Peter Anvin" <hpa@zytor.com>,
"James E.J. Bottomley" <jejb@parisc-linux.org>,
Julian Wiedmann <jwi@linux.vnet.ibm.com>,
Linux API <linux-api@vger.kernel.org>,
linux-arch <linux-arch@vger.kernel.org>,
"open list:RALINK MIPS ARCHITECTURE" <linux-mips@linux-mips.org>,
Parisc List <linux-parisc@vger.kernel.org>,
linuxppc-dev <linuxppc-dev@lists.ozlabs.org>,
linux-s390 <linux-s390@vger.kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Ingo Molnar <mingo@redhat.com>,
Michael Ellerman <mpe@ellerman.id.au>,
oberpar@linux.vnet.ibm.com, oprofile-list@lists.sf.net,
Paul Mackerras <paulus@samba.org>,
Peter Zijlstra <peterz@infradead.org>,
Ralf Baechle <ralf@linux-mips.org>,
Steven Rostedt <rostedt@goodmis.org>,
Robert Richter <rric@kernel.org>,
Martin Schwidefsky <schwidefsky@de.ibm.com>,
sebott@linux.vnet.ibm.com,
sparclinux <sparclinux@vger.kernel.org>,
Stefan Haberland <sth@linux.vnet.ibm.com>,
Ursula Braun <ubraun@linux.vnet.ibm.com>,
Will Deacon <will.deacon@arm.com>,
"the arch/x86 maintainers" <x86@kernel.org>
Subject: Re: [PATCH 0/9] posix_clocks: Prepare syscalls for 64 bit time_t conversion
Date: Fri, 17 Nov 2017 11:30:57 +0100 [thread overview]
Message-ID: <CAK8P3a10N42rBO8XBrZWYOCwVB8jayjgZu2oa8FSpHTzszQacQ@mail.gmail.com> (raw)
In-Reply-To: <alpine.DEB.2.20.1711171049180.1709@nanos>
On Fri, Nov 17, 2017 at 10:54 AM, Thomas Gleixner <tglx@linutronix.de> wrote:
> On Fri, 17 Nov 2017, Arnd Bergmann wrote:
>> On Fri, Nov 17, 2017 at 9:58 AM, Thomas Gleixner <tglx@linutronix.de> wrote:
>>
>> No, syscall that existing 32-bit user space enters would be handled by
>> compat_sys_nanosleep() on both 32-bit and 64-bit kernels at that
>> point. The idea here is to make the code path more uniform between
>> 32-bit and 64-bit kernels.
>
> So on a 32bit system compat_sys_nanosleep() would be the legacy
> sys_nanosleep() with the existing syscall number, but you don't want to
> introduce a new sys_nanosleep64() for 32bit. That makes a lot of sense.
>
> So back to your original question whether to use #if (MAGIC logic) or a
> separate config symbol. Please use the latter, these magic logic constructs
> are harder to read and prone to get wrong at some point. Having the
> decision logic in one place is always the right thing to do.
How about this:
config LEGACY_TIME_SYSCALLS
def_bool 64BIT || !64BIT_TIME
help
This controls the compilation of the following system calls:
time, stime,
gettimeofday, settimeofday, adjtimex, nanosleep, alarm, getitimer,
setitimer, select, utime, utimes, futimesat, and
{old,new}{l,f,}stat{,64}.
These all pass 32-bit time_t arguments on 32-bit architectures and
are replaced by other interfaces (e.g. posix timers and clocks, statx).
C libraries implementing 64-bit time_t in 32-bit architectures have to
implement the handles by wrapping around the newer interfaces.
New architectures should not explicitly disable this.
Arnd
next prev parent reply other threads:[~2017-11-17 10:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-10 22:42 [PATCH 0/9] posix_clocks: Prepare syscalls for 64 bit time_t conversion Deepa Dinamani
2017-11-10 22:42 ` [PATCH 1/9] include: Move compat_timespec/ timeval to compat_time.h Deepa Dinamani
2017-11-11 2:38 ` Steven Rostedt
2017-11-14 14:24 ` [PATCH 0/9] posix_clocks: Prepare syscalls for 64 bit time_t conversion Arnd Bergmann
2017-11-15 23:11 ` Deepa Dinamani
2017-11-16 9:04 ` Thomas Gleixner
2017-11-16 23:42 ` Arnd Bergmann
2017-11-17 8:58 ` Thomas Gleixner
2017-11-17 9:31 ` Arnd Bergmann
2017-11-17 9:54 ` Thomas Gleixner
2017-11-17 10:30 ` Arnd Bergmann [this message]
2017-11-17 10:40 ` Thomas Gleixner
2017-11-17 10:46 ` 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=CAK8P3a10N42rBO8XBrZWYOCwVB8jayjgZu2oa8FSpHTzszQacQ@mail.gmail.com \
--to=arnd@arndb.de \
--cc=acme@kernel.org \
--cc=benh@kernel.crashing.org \
--cc=borntraeger@de.ibm.com \
--cc=catalin.marinas@arm.com \
--cc=cmetcalf@mellanox.com \
--cc=cohuck@redhat.com \
--cc=davem@davemloft.net \
--cc=deepa.kernel@gmail.com \
--cc=deller@gmx.de \
--cc=devel@driverdev.osuosl.org \
--cc=gerald.schaefer@de.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=heiko.carstens@de.ibm.com \
--cc=hoeppner@linux.vnet.ibm.com \
--cc=hpa@zytor.com \
--cc=jejb@parisc-linux.org \
--cc=john.stultz@linaro.org \
--cc=jwi@linux.vnet.ibm.com \
--cc=linux-api@vger.kernel.org \
--cc=linux-arch@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@linux-mips.org \
--cc=linux-parisc@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=mpe@ellerman.id.au \
--cc=oberpar@linux.vnet.ibm.com \
--cc=oprofile-list@lists.sf.net \
--cc=paulus@samba.org \
--cc=peterz@infradead.org \
--cc=ralf@linux-mips.org \
--cc=rostedt@goodmis.org \
--cc=rric@kernel.org \
--cc=schwidefsky@de.ibm.com \
--cc=sebott@linux.vnet.ibm.com \
--cc=sparclinux@vger.kernel.org \
--cc=sth@linux.vnet.ibm.com \
--cc=tglx@linutronix.de \
--cc=ubraun@linux.vnet.ibm.com \
--cc=will.deacon@arm.com \
--cc=x86@kernel.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).