All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Stultz <john.stultz@linaro.org>
To: David Vrabel <david.vrabel@citrix.com>
Cc: xen-devel@lists.xen.org,
	Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
	linux-kernel@vger.kernel.org,
	Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [PATCHv3 0/2] xen: maintain an accurate persistent clock in more cases
Date: Thu, 30 May 2013 16:55:53 -0700	[thread overview]
Message-ID: <51A7E709.9080309@linaro.org> (raw)
In-Reply-To: <1369923919-26981-1-git-send-email-david.vrabel@citrix.com>

On 05/30/2013 07:25 AM, David Vrabel wrote:
> The kernel has limited support for updating the persistent clock or
> RTC when NTP is synced.  This has the following limitations:
>
> * The persistent clock is not updated on step changes.  This leaves a
>    window where it will be incorrect (while NTP resyncs).
>
> * Xen guests use the Xen wallclock as their persistent clock.  dom0
>    maintains this clock so it is persistent for domUs and not dom0
>    itself.


So I'm still skeptical of the urgency to the first patch in this series, 
as I feel its a little overzealous in trying to enforce strict 
RTC/system-time synchronization.  But that said, these patches are now 
done in a way that doesn't affect the timekeeping core, so I'm ok with 
stepping out of the way and leaving the decision to merge it up to the 
Xen maintainers (Modulo a few nits I still have).


> These series fixes the above limitations and depends on "x86: increase
> precision of x86_platform.get/set_wallclock()" which was previously
> posted.

This is the only area that will need some coordination cross the Xen 
tree and tip/timers/core (once that patch and the fix for it I have 
queued lands in -tip). The options here are:

* I queue these two patches with proper Xen maintainer's acks/review 
(possibly adding my grumbles to the commit)
* Wait until the requried patch lands tip/timers/core, then Xen 
maintainers merge tip/timers/core into their tree as well
* These patches get rewritten so they don't depend on the "increase 
precision" patch, then we sort out the merge in -next


The first is probably the easiest, but I do want to make sure that Xen 
maintainers agree that Xen really needs to be special here compared to 
every other platform and always enforce the RTC is synced with system time.


> [ On a related note, with CONFIG_HZ=1000 sync_cmos_clock() is always
>    scheduled ~3ms too late which causes it to repeatedly try to
>    reschedule in ~997 ms and ends up never calling
>    updated_persistent_clock().  With HZ=250, the error is ~1ms too late
>    which is close enough.
>
>    It is not clear where this systematic error comes from or whether
>    this is only a Xen specific bug.  I don't have time to investigate
>    right now. ]

I'd be very interested in hearing more about this issue!

thanks
-john


  parent reply	other threads:[~2013-05-30 23:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-30 14:25 [PATCHv3 0/2] xen: maintain an accurate persistent clock in more cases David Vrabel
2013-05-30 14:25 ` [PATCH 1/2] x86/xen: sync the wallclock when the system time changes David Vrabel
2013-05-31  0:30   ` John Stultz
2013-05-31  0:30   ` John Stultz
2013-05-31  9:49     ` David Vrabel
2013-05-31  9:49     ` David Vrabel
2013-05-31 20:21       ` John Stultz
2013-05-31 20:21       ` John Stultz
2013-05-30 14:25 ` David Vrabel
2013-05-30 14:25 ` [PATCH 2/2] x86/xen: sync the CMOS RTC as well as the Xen wallclock David Vrabel
2013-05-30 14:25 ` David Vrabel
2013-05-30 23:55 ` John Stultz [this message]
2013-05-31  7:52   ` [Xen-devel] [PATCHv3 0/2] xen: maintain an accurate persistent clock in more cases Jan Beulich
2013-05-31  7:52   ` Jan Beulich
2013-05-31  9:56   ` David Vrabel
2013-05-31  9:56   ` David Vrabel
2013-05-30 23:55 ` John Stultz
  -- strict thread matches above, loose matches on Subject: below --
2013-05-30 14:25 David Vrabel

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=51A7E709.9080309@linaro.org \
    --to=john.stultz@linaro.org \
    --cc=david.vrabel@citrix.com \
    --cc=konrad.wilk@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tglx@linutronix.de \
    --cc=xen-devel@lists.xen.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.