[LinuxPPS] Patches for kernel 2.6.26-rc8
Hal V. Engel
hvengel at astound.net
Sun Jul 6 18:03:36 CEST 2008
On Sunday 06 July 2008 08:52:54 am Hal V. Engel wrote:
> On Sunday 06 July 2008 07:14:15 am Bernhard Schiffner wrote:
> > On Sunday 06 July 2008 10:31:38 Hal V. Engel wrote:
> > ...
> >
> > > Second ntp appears to be running in microsecond mode rather than
> > > nanosecond mode even though I built it against the new kernel header
> > > files. When I run ntptime I get:
> > >
> > >
> > > ntp_gettime() returns code 0 (OK)
> > > time cc1a25a4.f3dc6000 Sat, Jul 5 2008 9:53:56.952, (.952581),
> > > maximum error 2561 us, estimated error 12 us
> > > ntp_adjtime() returns code 0 (OK)
> > > modes 0x0 (),
> > > offset 72.000 us, frequency -24.429 ppm, interval 1 s,
> > > maximum error 2561 us, estimated error 12 us,
> > > status 0x1 (PLL),
> > > time constant 4, precision 1.000 us, tolerance 500 ppm,
> > >
> > >
> > > As you can see the precision is 1.000 us. I built ntp after setting up
> > > the symllinks in /usr/include that are used to build the LinuxPPS
> > > userland tools. I had expected that the ntp build would find STA_NANO
> > > defined in /usr/include/timex.h and that it would do the correct thing.
> > > I also tried adding STA_NANO and the other related defines to
> > > kernel/sys/timex.h in the ntp source tree but I still end up with a
> > > non-nano ntp. It appears there something else that I need to do to
> > > get ntp into nanosecond mode but I have no idea what that would be. Do
> > > I need to do something to the kernel (I couldn't find any place to make
> > > any config settings that looked like it would affect this)? Do I need
> > > to build a newer version of ntp (I have tried 4.2.4_p4 and 4.2.5p118)?
> > > Or do I need to use a commad line switch when starting ntpd or
> > > something in the configuration file?
> >
> > Ther are (small but important) differerences between /usr/include/linux
> > and /usr/src/kernel/include/linux.
> > One is what the distributor cleaned up for your use, working with a lot
> > of different kernels too. The other is the recent opinion of the
> > kernel-community.
> > Test this please to get it right.
>
> What should I test? Are you saying that I should build ntp without the
> symlinked directories? I will give that a try.
This did not work. If I build ntp without the symlinked directories in
/usr/include it will not work with the PPS device.
>
> > A symlink may help for a first shot, but don't trash the content
> > of /usr/include/linux to fast.
>
> The symlinks are temperary and strictly to build the LinuxPPS user land
> tools and (I think but maybe I am wrong) ntp. If I leave them in place
> many other things on my system will go haywire since I run a source based
> distro (IE. I can not do any updates with these in place). I personally
> don't like the fact that LinuxPPS currently requires these symlinked
> directories to build the userland tools and this is something that needs to
> be fixed hopefully sooner rather than later. It clearly needs to be fixed
> before LinuxPPS becomes part of the kernel. I have not changed
> /usr/include at all and as soon as I have a working ntp I will remove the
> symlinks and restore the standard directories.
>
>
> At this point I am convinced that I don't understand how to build ntp to
> work with kernel 2.6.26-rc8 with the LinuxPPS patches. This kernel by
> default is a nanokernel so at some point ntp will need to be fixed up to
> build correctly out of the box but that does not appear to be the case at
> this point even with the most recent ntp snapshot. I have spent a lot of
> time on the net trying to find anything that might be useful about this.
> Since all of the things I am finding are from the PPSKit time frame I have
> not found anything useful and most of it is totally wrong.
>
>
> Hal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ml.enneenne.com/pipermail/linuxpps/attachments/20080706/cb14245e/attachment-0001.htm
More information about the LinuxPPS
mailing list