mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Richard Cochran <richardcochran@gmail.com>
To: John Stultz <john.stultz@linaro.org>
Cc: linux-kernel@vger.kernel.org, Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [PATCH RFC V1 0/5] Rationalize time keeping
Date: Sat, 5 May 2012 09:34:08 +0200	[thread overview]
Message-ID: <20120505073408.GC1967@netboy.at.omicron.at> (raw)
In-Reply-To: <4FA2E334.7040601@linaro.org>

On Thu, May 03, 2012 at 12:57:40PM -0700, John Stultz wrote:
> On 04/27/2012 01:12 AM, Richard Cochran wrote:
> >
> >The basic idea is to keep the internal time using a continuous
> >timescale and to convert to UTC by testing the time value against the
> >current threshold and adding the appropriate offset. Since the UTC
> >time and the leap second status is provided on demand, this eliminates
> >the need to set a timer or to constantly monitor for leap seconds, as
> >was done up until now.
> 
> So as I mentioned in my earlier review of this patch set, I'm not as
> excited about the meta-layer you added in utc-tai.h.

It really isn't a layer. It is just a pair of static inline helper
functions. The code could just as well be internal to timekeeper.c,
but I put it in its own file so that I could include it into a unit
test program.

> http://git.linaro.org/gitweb?p=people/jstultz/linux.git;a=shortlog;h=refs/heads/dev/clktai
> 
> The untested patch set there basically pushes TAI time management
> into the timekeeping core, and then exports a CLOCK_TAI clockid.
> 
> This patch set *does not* address the tick-granularity delayed
> leap-second processing issue that your patch also addresses. But I
> feel like the basic handling of tai is a little simpler.

So, is this a "won't fix" issue, in your view?

(If so, I'll drop it.)
 
> Take a look at it and let me know what you think.

It looks okay to me, as far as it goes.

At least you offer a clock that doesn't jump around. With your patches
(and the TAI offset fix before), user space programs sensitive to the
leap second uglies would have a reasonable option. Data collection
programs can read and store TAI time stamps, and these can always be
converted into UTC using a table method.

But do you think it will be possible to implement the following in the
same way?

- clock_settime(CLOCK_TAI)
- clock_adjtime(CLOCK_TAI)
- timer_create(CLOCK_TAI)

Thanks,
Richard

  reply	other threads:[~2012-05-05  7:34 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-27  8:12 Richard Cochran
2012-04-27  8:12 ` [PATCH RFC V1 1/5] Add functions to convert continuous timescales to UTC Richard Cochran
2012-04-27  8:12 ` [PATCH RFC V1 2/5] ntp: Fix a stale comment and a few stray newlines Richard Cochran
2012-04-27 22:25   ` John Stultz
2012-04-27  8:12 ` [PATCH RFC V1 3/5] timekeeping: Fix a few minor newline issues Richard Cochran
2012-04-27 22:25   ` John Stultz
2012-04-27  8:12 ` [PATCH RFC V1 4/5] timekeeping: Offer an interface to manipulate leap seconds Richard Cochran
2012-04-27 23:08   ` John Stultz
2012-04-28  8:47     ` Richard Cochran
2012-05-05 10:17     ` Richard Cochran
2012-05-07 17:36       ` John Stultz
2012-04-27  8:12 ` [PATCH RFC V1 5/5] timekeeping: Use a continuous timescale to tell time Richard Cochran
2012-05-28 16:49   ` Richard Cochran
2012-04-27 22:49 ` [PATCH RFC V1 0/5] Rationalize time keeping John Stultz
2012-04-28  8:04   ` Richard Cochran
2012-04-30 20:56     ` John Stultz
2012-05-01  7:17       ` Richard Cochran
2012-05-01  8:01         ` John Stultz
2012-05-01 18:43           ` Richard Cochran
2012-05-03  7:02       ` Richard Cochran
2012-05-03 15:48         ` John Stultz
2012-05-03 18:21   ` Richard Cochran
2012-05-03 18:44     ` John Stultz
2012-05-03 19:28       ` Richard Cochran
2012-05-03 19:42         ` John Stultz
2012-05-03 19:57 ` John Stultz
2012-05-05  7:34   ` Richard Cochran [this message]
2012-05-05 19:25     ` John Stultz

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=20120505073408.GC1967@netboy.at.omicron.at \
    --to=richardcochran@gmail.com \
    --cc=john.stultz@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tglx@linutronix.de \
    /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

Powered by JetHome