and the "kernel.tar.Z" distribution on louie.udel.edu, which is older than
xntp 3.4y or 3.5a, but contains newer kernel source fragments.
This commit adds support for a new kernel configuration option, NTP.
If NTP is selected, then the system clock should be run at "HZ", which
must be defined at compile time to be one value from:
60, 64, 100, 128, 256, 512, 1024.
Powers of 2 are ideal; 60 and 100 are supported but are marginally less
accurate.
If NTP is not configured, there should be no change in behavior relative
to pre-NTP kernels.
These changes have been tested extensively with xntpd 3.4y on a decstation;
almost identical kernel mods work on an i386. No pulse-per-second (PPS)
line discipline support is included, due to unavailability of hardware
to test it.
With this in-kernel PLL support for NetBSD, both xntp 3.4y and xntp
3.5a user-level code need minor changes. xntp's prototype for
syscall() is correct for FreeBSD, but not for NetBSD.
(1) text calculation incorrect (would 'overbill')
(2) data calculation incorrect (would 'overbill')
(3) the maxrss calculation uses stuff which isn't present
on the sparc.
if 3/4 tests are questionable and/or broken, well...
* cleaned up hardclock() to avoid checking "p" multiple times, and avoid a
gcc2 possible-use-before-initialisation warning.
* changed softclock() timeout callback functions to be of type timeout_t -
a pointer to a void fn(int). No-one was using the second, tick, argument
that was being passed to these callbacks - it is much cleaner to drop the
thing entirely, rather than add a whole heap of casts of dubious
correctness to calls to timeout(), etc. The old style is kept in an
#ifdef, for future reference.