From: Thomas Gleixner <tglx@linutronix.de>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mark Salyzyn <salyzyn@android.com>,
Petr Mladek <pmladek@suse.com>,
LKML <linux-kernel@vger.kernel.org>,
Ingo Molnar <mingo@kernel.org>, "H. Peter Anvin" <hpa@zytor.com>,
Peter Zijlstra <peterz@infradead.org>,
Andrew Morton <akpm@linux-foundation.org>,
Prarit Bhargava <prarit@redhat.com>,
Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
Steven Rostedt <rostedt@goodmis.org>,
John Stultz <john.stultz@linaro.org>
Subject: Re: [GIT pull] printk updates for 4.15
Date: Thu, 16 Nov 2017 01:37:41 +0100 (CET) [thread overview]
Message-ID: <alpine.DEB.2.20.1711160011300.2146@nanos> (raw)
In-Reply-To: <CA+55aFz44J+fs72JckP_F_DvFJnb1kJ72OAvFj+e-+gCtS9RQA@mail.gmail.com>
On Wed, 15 Nov 2017, Linus Torvalds wrote:
>
> So I agree with all of this, but I wonder what actuall yuses that
> BOOTTIME to make it worth even synchronizing with.
>
> I'm assuming it's some evdev user.
>
> But I'm wondering if perhaps we could just simplify our own lives and
> make CLOCK_BOOTTIME and CLOCK_MONOTONIC just be the same.
>
> And we'd make them be the same by making CLOCK_MONOTONIC act like
> CLOCK_BOOTTIME.
>
> I doubt anybody would notice.
>
> At least we could _try_ that kind of system clock simplification.
> Maybe people would scream bloody murder and we'd have to revert, but
> wouldn't it be lovely to simplify the synchronization problem by just
> making it go away (well, at least for the BOOTTIME/MONOTONIC case).
Yes it would be lovely. I have some vague memories about having MONOTONIC
behave the same way as BOOTTIME in the early days of the generic
timekeeping infrastructure, high resolution timers and idle NOHZ work, 10+
years ago.
This broke stuff because the historic behaviour was to not advance on
resume and the change caused massive timer expiries right after resume
which confused the hell out of things, because timers fired immediately
which were not expected to fire as they were implicitely relying on suspend
not affecting clock monotonic.
So we reverted back to the old behaviour.
Soon after that, people complained about not being able to arm timers which
should expire after a resume or get access to the time spent there, but
they could not use REALTIME due to time jumps caused by DST and
whatever. So we introduced BOOTTIME.
In hindsight it might have been better not to do that, but now we have to
deal with it.
I'm a bit worried to change that because the behaviour difference of
MONOTONIC and BOOTTIME vs. suspend/resume is well documented all over the
place and there are explicit choices made in applications and libraries
which one of them to use for a particular problem. So I expect that some of
the surprises we've seen 10+ years ago still persist.
I'm also quite sure that there is kernel code which relies implicitely on
that behaviour. We surely can fix that, but it might be tedious to debug.
John?
Thanks,
tglx
next prev parent reply other threads:[~2017-11-16 0:38 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-13 9:36 Thomas Gleixner
2017-11-14 1:18 ` Linus Torvalds
2017-11-14 2:48 ` Linus Torvalds
2017-11-14 10:03 ` Petr Mladek
2017-11-14 13:28 ` Prarit Bhargava
2017-11-14 15:56 ` Mark Salyzyn
2017-11-15 0:48 ` Sergey Senozhatsky
2017-11-14 17:20 ` Linus Torvalds
2017-11-14 20:21 ` Thomas Gleixner
2017-11-14 21:07 ` Linus Torvalds
2017-11-14 21:09 ` Thomas Gleixner
2017-11-14 21:16 ` Mark Salyzyn
2017-11-14 21:29 ` Linus Torvalds
2017-11-14 22:10 ` Mark Salyzyn
2017-11-14 22:37 ` Linus Torvalds
2017-11-14 22:50 ` Thomas Gleixner
2017-11-14 23:00 ` Joe Perches
2017-11-14 23:00 ` Linus Torvalds
2017-11-14 23:04 ` Thomas Gleixner
2017-11-14 23:18 ` Linus Torvalds
2017-11-14 23:22 ` Thomas Gleixner
2017-11-15 0:00 ` Linus Torvalds
2017-11-15 8:04 ` Ingo Molnar
2017-11-15 16:26 ` Mark Salyzyn
2017-11-15 17:42 ` Linus Torvalds
2017-11-16 0:37 ` Thomas Gleixner [this message]
2017-11-16 1:23 ` John Stultz
2017-11-16 1:32 ` Linus Torvalds
2017-11-16 7:12 ` Thomas Gleixner
2017-11-18 0:26 ` Thomas Gleixner
2017-11-18 0:44 ` Linus Torvalds
2017-11-18 1:00 ` Thomas Gleixner
2017-11-20 6:20 ` Kevin Easton
2017-11-20 6:36 ` Linus Torvalds
2018-01-29 20:34 ` Mark Salyzyn
2018-01-29 21:49 ` Thomas Gleixner
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=alpine.DEB.2.20.1711160011300.2146@nanos \
--to=tglx@linutronix.de \
--cc=akpm@linux-foundation.org \
--cc=hpa@zytor.com \
--cc=john.stultz@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=pmladek@suse.com \
--cc=prarit@redhat.com \
--cc=rostedt@goodmis.org \
--cc=salyzyn@android.com \
--cc=sergey.senozhatsky@gmail.com \
--cc=torvalds@linux-foundation.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
all inboxes | Powered by JetHome®