[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z-5HlSUEh1xgCi4f@localhost>
Date: Thu, 3 Apr 2025 10:32:21 +0200
From: Miroslav Lichvar <mlichvar@...hat.com>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: John Stultz <jstultz@...gle.com>, LKML <linux-kernel@...r.kernel.org>,
Stephen Boyd <sboyd@...nel.org>,
Anna-Maria Behnsen <anna-maria@...utronix.de>,
Frederic Weisbecker <frederic@...nel.org>,
Shuah Khan <shuah@...nel.org>, linux-kselftest@...r.kernel.org,
kernel-team@...roid.com, Lei Chen <lei.chen@...rtx.com>
Subject: Re: [PATCH v2 1/2] time/timekeeping: Fix possible inconsistencies in
_COARSE clockids
On Tue, Apr 01, 2025 at 08:29:23PM +0200, Thomas Gleixner wrote:
> On Tue, Apr 01 2025 at 13:19, Miroslav Lichvar wrote:
> > It seems to improve the worst cases, but overall it's still
> > a regression.
> >
> > Mult reduction Updates/sec Skew
> > 16 4 0.012
> > 16 16 0.014
> > 16 64 0.033
> > 64 4 0.012
> > 64 16 0.105
> > 64 64 0.138
>
> That's weird as it only delays the update to the next tick.
Ok, so it's not an instability of the clock, but rather an instability
of the chronyd synchronization loop, which since kernel 4.19 expects
the frequency to be applied as soon as the adjtimex call is finished.
To confirm that, I tried a different test with chronyd configured to
only monitor the clock without making any adjustments (-x option) and
another process repeatedly setting the same frequency. The one-line
patch does fix that test.
> My original
> approach of maintaining seperate state for the coarse time keeper is
> preserving the existing NTP behaviour.
>
> Patch applies after reverting 757b000f7b93 ("timekeeping: Fix possible
> inconsistencies in _COARSE clockids").
I ran multiple longer tests to be able to compare the small values in
the noise and yes, from the adjtimex point of view this seems to work
as well as before the first COARSE fix. I didn't run any tests of the
COARSE clock.
Thanks,
--
Miroslav Lichvar
Powered by blists - more mailing lists