netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Richard Cochran <richardcochran@gmail.com>
To: Russell King - ARM Linux admin <linux@armlinux.org.uk>
Cc: Vladimir Oltean <olteanv@gmail.com>, netdev@vger.kernel.org
Subject: Re: phc2sys - does it work?
Date: Mon, 27 Jul 2020 07:10:15 -0700	[thread overview]
Message-ID: <20200727141015.GA16836@hoboy> (raw)
In-Reply-To: <20200726212952.GF1551@shell.armlinux.org.uk>

On Sun, Jul 26, 2020 at 10:29:53PM +0100, Russell King - ARM Linux admin wrote:
> I have noticed that phc2sys can sometimes get confused and it needs
> phc_ctl to reset the frequency back to zero for it to have another go.
> The hardware is capable of a max_adj of S32_MAX, and I think that
> allows phc2sys to get confused sometimes, so I probably need to clamp
> my calculated max_adj to a sane limit.  Is there an upper limit that
> phc2sys expects?

The program uses the minumum of the PHC's max_adj and the
max_frequency configuration value (whose default is 900000000).

In general, huge frequency corrections are a sign that something is
wrong.  If your setup has sudden phase jumps (like ntpd resetting the
clock), then you should consider allowing phc2sys to jump as well.
For example, I use

     phc2sys -S 0.128

which allows phc2sys to jump when the offset is greater that 128
milliseconds.  That value is chosen to match ntpd's threshold for
jumping the time.

HTH,
Richard

  reply	other threads:[~2020-07-27 14:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-25 12:49 phc2sys - does it work? Russell King - ARM Linux admin
2020-07-25 13:29 ` Vladimir Oltean
2020-07-26 11:01   ` Russell King - ARM Linux admin
2020-07-26 18:05     ` Richard Cochran
2020-07-26 21:29       ` Russell King - ARM Linux admin
2020-07-27 14:10         ` Richard Cochran [this message]
2020-07-26 19:53     ` Vladimir Oltean

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=20200727141015.GA16836@hoboy \
    --to=richardcochran@gmail.com \
    --cc=linux@armlinux.org.uk \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    /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).