PPSkit-0.3.0 available (new NTP PPS patch)

Ulrich Windl (wiu09524@pc3103.klinik.uni-regensburg.de)
Mon, 15 Sep 1997 09:27:51 +0200 (CEST)


I'm

happy that I finally got a new version of my PPS patch for Linux
available. As per masters request I moved to 3.0.31-pre9 as basis of the
patch. (Still it'l work for 2.0.30 and few older releases, too)

I also realized that my old patch contained two files twice because of
symbolic links being followed (asm and asm-i386). Should be better this
time.

Before I forget it:
ftp://pcphy4.physik.uni-regensburg.de/pub/wiu09524/PPS/PSkit-0.3.0.tar.gz/
about 30kB.

For the curious, here's the (new) NEWS file:

(Emacs: -*- indented-text -*-)

What's new?

NEWS for 0.3.0

+ I decided to break the single text file with everything into a more
friendly archive, even if I'll surely exceed 20kB for the first
time. The version number will present ``political version
numbering'' (as opposed to ``chronological or automated version
numbering''. So we have `0', a version that's not yet perfect;
`3', the third mayor attempt to make things better; finally we have
`0', a release that wants testing.

+ new ioctl CIOGETEV was implemented in the hope it can be used from
xntpd. I used a trimmed-down version of Harald Koenig's patch
(k-dcf.patch-1.3.58). The time stamps are used for both, the PPS
routine and the line discipline.

+ implementation of TIOCDCDTIMESTAMP was removed again because of the
change to serial struct. Furthermore the new CIOGETEV can do things
even better (it has an event counter)

+ Much improved testing program (I hope; in fact it's almost
completely rewritten). User-visible changes include better error
reporting and edge detection selectable from command line.

+ Possibly improved pulse generator including emulations for common
errors (see BUGS).

+ CONFIG_HARD_PPS is CONFIG_PPS_SYNC now (for no very good reason)...

+ Major corrections to the kernel, especially `adjtimex':

* All parameters are checked now. Previously several parameters
were unchecked.

* It's no longer allowed to change read-only status bits, but
still no error is returned, because it seems that's how xntpd
expects things to work (it's easier that way).

* A plain old `adjtime()' can be done independent of any
STA_-settings (that's what the memorandum says about
compatibility with existing applications)

* Avoided some `if's by grouping checking and setting of values
together (where it was easy ;-))

* `adjtimex' now returns an error depending on several status bits
(e.g. when you enable STA_PPSFREQ when there is no
STA_PPSSIGNAL)

+ (kernel/sched.c) If the clock's maximum error reached
NTP_PHASE_LIMIT (16 seconds as per memorandum), the clock is
declared STA_UNSYNC, and the time state will be TIME_ERROR. The
specification is not too clear on the latter point.

+ The CMOS clock is now updated if STA_UNSYNC is cleared (and no
longer if time_state is not TIME_ERROR).

+ The `hardware_pps' (hardpps) routine has two parameters now, the
timeval and the hardware counter (microtime). Changed for no good
reason. Fixed a bug that required 5 good calibrations before the
interval was increased (memorandum talks about 4).

+ Added some comments (at various places), reformatted some lines,
added debugging code, etc.

+ (arch/i386/kernel/time.c) The code to update the CMOS clock is
broken! I was unsure how to fix it, so I added a warning message if
the code fails. This has to be fixed soon!

+ (drivers/char/serial.c) The version of the driver has been changed
by adding a 'a'. In addition the option `PPS' has been defined for
CONFIG_PPS_SYNC. The code to print the startup message has been
improved (a matter of taste).

BAD NEWS: There are no NEWS before 0.3.0

Ulrich Windl