How do I enable PLL in the Linux kernel? - NTP

This is a discussion on How do I enable PLL in the Linux kernel? - NTP ; Hi, the manual for the ntpdc program says the following about the "kerninfo" command: "Obtain and print kernel phase-lock loop operating parameters. This information is available only if the kernel has been specially modified for a precision timekeeping function." The ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: How do I enable PLL in the Linux kernel?

  1. How do I enable PLL in the Linux kernel?

    Hi,

    the manual for the ntpdc program says the following about the "kerninfo"
    command:

    "Obtain and print kernel phase-lock loop operating parameters. This
    information
    is available only if the kernel has been specially modified for a
    precision
    timekeeping function."

    The output I get from kerninfo is the following:

    ntpdc> kern
    pll offset: 0 s
    pll frequency: 0.000 ppm
    maximum error: 0.414224 s
    estimated error: 1.6e-05 s
    status: 0040 unsync
    pll time constant: 4
    precision: 1e-06 s
    frequency tolerance: 512 ppm

    My questions are:
    * What does "0040 unsync" mean?
    * Does this inform me that my
    kernel has NOT been "specially modified for
    a precision timekeeping function."?
    * How do I make sure the PLL is enabled?
    * Does the PLL feature require special hardware?

    Best regards,
    Anton Persson, Ericsson Sweden.

  2. Re: How do I enable PLL in the Linux kernel?

    Anton Persson A wrote:

    > The output I get from kerninfo is the following:
    >
    > ntpdc> kern
    > pll offset: 0 s
    > pll frequency: 0.000 ppm
    > maximum error: 0.414224 s
    > estimated error: 1.6e-05 s
    > status: 0040 unsync
    > pll time constant: 4
    > precision: 1e-06 s
    > frequency tolerance: 512 ppm
    >
    > My questions are:
    > * What does "0040 unsync" mean?


    From /usr/include/sys/timex.h on Linux 2.4:

    #define STA_UNSYNC 0x0040 /* clock unsynchronized (rw) */


    > * Does this inform me that my
    > kernel has NOT been "specially modified for
    > a precision timekeeping function."?


    No. The system call that provides this information would not have been
    present if there was no support.

    > * How do I make sure the PLL is enabled?


    From miscopt.html in the documentation supplied with ntpd version
    4.2.4p4, although possibly omitted by vendors:

    enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps |
    stats]
    disable [ auth | bclient | calibrate | kernel | monitor | ntp |
    pps | stats ]
    Provides a way to enable or disable various system
    options. Flags not mentioned are unaffected. Note
    that all of these flags can be controlled remotely
    using the ntpdc utility program.
    ....
    kernel
    Enables the kernel time discipline, if available.
    The default for this flag is enable if support is
    available, otherwise disable.

    and from ntpdc.html, in the same place:

    enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps |
    stats]
    disable [ auth | bclient | calibrate | kernel | monitor | ntp |
    pps | stats]
    These commands operate in the same way as the enable
    and disable configuration file commands of ntpd. See
    the Miscellaneous Options page for further information.

    > * Does the PLL feature require special hardware?


    We are not talking about a "PLL feature"; ntpd always uses a PLL when
    disciplining the clock. We are talking about the kernel feature, where
    the PLL runs in the kernel, rather than the ntpd application. Neither
    require special hardware.


    Generally, I would only expect kerninfo to say unsynced, out of the box,
    if more conventional indications of a failure to synchronise (ntpq
    peers) were also showing unsynchronised. I'm wondering if you are
    looking too deep for a a problem that would better be diagnosed with
    ntpq peers and ntpq rv output.
    >


  3. Re: How do I enable PLL in the Linux kernel?

    Anton,

    See rfc2783 and header file timex.h.

    Dave

    Anton Persson A wrote:
    > Hi,
    >
    > the manual for the ntpdc program says the following about the "kerninfo"
    > command:
    >
    > "Obtain and print kernel phase-lock loop operating parameters. This
    > information
    > is available only if the kernel has been specially modified for a
    > precision
    > timekeeping function."
    >
    > The output I get from kerninfo is the following:
    >
    > ntpdc> kern
    > pll offset: 0 s
    > pll frequency: 0.000 ppm
    > maximum error: 0.414224 s
    > estimated error: 1.6e-05 s
    > status: 0040 unsync
    > pll time constant: 4
    > precision: 1e-06 s
    > frequency tolerance: 512 ppm
    >
    > My questions are:
    > * What does "0040 unsync" mean?
    > * Does this inform me that my
    > kernel has NOT been "specially modified for
    > a precision timekeeping function."?
    > * How do I make sure the PLL is enabled?
    > * Does the PLL feature require special hardware?
    >
    > Best regards,
    > Anton Persson, Ericsson Sweden.


+ Reply to Thread