Kernel PLL graphs

Hal Murray hmurray at megapathdsl.net
Mon Aug 1 09:40:11 UTC 2016


There are two parts to PPS processing in the kernel.  RFC 2783 describes an 
API for capturing time stamps.  RFC 1589 describes a PLL that lives in the 
kernel.

Most Linux distros don't support RFC 1589.  The code is in the kernel, but it doesn't work with the shipped kernels.  It requires !NO_HZ, but most distros prefer NO_HZ.

I pulled over the sources and built my own kernel.

Here are the before and after graphs:
  http://users.megapathdsl.net/~hmurray/ntpsec/PPS-kernel.png
The data is from two separate days so this isn't a clean comparison.  I don't know what that machine was doing on either day.

Here is a zoom in on the Kernel PLL day.
  http://users.megapathdsl.net/~hmurray/ntpsec/PPS-kernel2.png
Note that the peak offset is less than a microsecond.

------------

We should see if we can get similar results on a Raspberry Pi.  I haven't tried building an ARM kernel.

I think we should be able to run the PLL code outside the kernel.  The PPS time stamp is key.  The PLL calculations don't need to be run in the kernel.  They need to be run soon after the PPS, but not interrupt level immediately.  The API has an option to wakeup on PPS.  I don't know if it is implemented on Linux.

The no-PLL test was run at the default maxpoll of 6.  I should try faster.  I also need a standard test load.

I remember various FreeBSD-is-better type comments from many years ago.  I don't know if the PLL was working in Linux at the time.  I should setup a test case.


-- 
These are my opinions.  I hate spam.





More information about the devel mailing list