Harlan Stenn [Mon, 27 Nov 2000 04:48:13 +0000 (04:48 -0000)]
Many files:
* configure.in: 4.0.99k11
* ntpd/ntp_proto.c (transmit):
* ntpd/ntp_peer.c:
* ntpd/ntp_io.c:
* ntpd/ntp_control.c (ctl_putpeer):
* ntpd/ntp_config.c (getconfig):
* include/ntpd.h: mcast/ucast interface cleanup.
From: Dave Mills
* include/ntp_request.h: Put data[] as MAXFILENAME+16. This will
fix the conf_peer requests again, but re-break compatibility with
old versions of the daemon. Sigh.
Harlan Stenn [Mon, 20 Nov 2000 00:12:25 +0000 (00:12 -0000)]
ChangeLog, refclock_parse.c, refclock_pcf.c:
* ntpd/refclock_parse.c (rawdcf_init_1): make Linux happier with
some modem control stuff.
From: Wolfram Pienkoss <wp@bszh.de> (via Frank Kardel)
* ntpd/refclock_pcf.c (pcf_poll): isdst fix
From: Andreas Voegele <andreas.voegele@gmx.de>
Sven Dietricht [Sun, 19 Nov 2000 09:02:12 +0000 (09:02 -0000)]
nt_clockstuff.c:
From: Ron Thornton [rthornto@pictel.com]
Sent: Thu 11/16/00 8:51 AM
On Windows 2000 it requires a privilege on the current process token
that is disabled by default on Windows 2000.
I set the token by adding the following code at the beginning of the
init_winnt_time() function in nt_clockstuff.c.
Sven Dietricht [Sun, 19 Nov 2000 08:39:09 +0000 (08:39 -0000)]
machines.c:
From: Ron Thornton [rthornto@pictel.com]
In libntp/machines.c, the getpass() function is implemented for
SYS_WINNT using the _getch() call. On my NT 4.0 systems, the enter key
does not return '\n' so the password read does not end.
To work around the problem, I must enter Ctrl-J (linefeed) to terminate
the password entry.
To fix the problem, I had to change "((c=_getch())!='\n')" to
"((c=_getch())!='\n' && c!='\r')" in machines.c
I left the test for \n (linefeed) in the event microsoft alters _getch()
in the future and added the test for \r (enter/carrage return) to cope
with the current implementation of _getch()
Sven Dietricht [Sun, 19 Nov 2000 08:03:20 +0000 (08:03 -0000)]
nt_clockstuff.c:
From: "Colin Dancer" <colin.dancer@pyrochrome.net>
To: <bugs@ntp.org>
Sent: 10 November 2000 12:59
Subject: NT bug in NTP 4.0.99j
I've found a bug in (and produced a fix for) the NT clock interpolation
code in NTP 4.0.99j.
The symptoms of the problem are that gettimeofday() function on NT
can be wrong by hundreds of seconds if, while a gettimeofday() call
is being processed, an APC completes after the query of the performance
counter but before the lock is grabbed. The most obvious fix is to move
the lock to include the querying of the performance counter, but this
could affect the predictability of the timestamp so I have instead
tweaked the code to detect and sidestep the duff calculation.
I've also found that on a loaded system the execution of the APC can be
delayed, leading to errors of upto 10ms. There is no easy fix to this,
but I do have code for an alternative interpolation scheme which avoids
the problem on single processor systems. I'm currently integrating this
along with code for deciding which algorithm to use based on whether
the system is SP or MP.
Harlan Stenn [Sat, 28 Oct 2000 07:42:08 +0000 (07:42 -0000)]
Many files:
* ntpd/refclock_wwvb.c (wwvb_start): Cosmetic reorder.
* ntpd/refclock_atom.c (RANGEGATE): Cleanup. Add ASTAGE.
Add ppsparams to struct ppsunit.
(atom_start): Init peer->burst to ASTAGE.
(atom_shutdown): Multi-handle
(atom_pps): Multi-handle
(atom_pps): RANGEGATE cleanup
(atom_poll): Poll count cleanup. Error check cleanup. Burst cleanup.
* ntpd/ntp_refclock.c (refclock_transmit): Lose the pre-burst
check poll_update().
(refclock_sample): Fix the jitter calc.
(refclock_receive): Pass the jitter to the clock_filter().
* ntpd/ntp_proto.c (clock_update): If we lose sync, reset the poll
to NTP_MINDPOLL.
(poll_update): Poll wiggles. Make sure peer->nextdate is timely.
(clock_select): If we lose sync, reset the poll to NTP_MINDPOLL.
* ntpd/ntp_loopfilter.c (local_clock): Show the asocid in debug
output. popcorn debug message changes. Clamp the poll interval
if the system peer has changed. PPS wiggle changes.
From Dave Mills.
ChangeLog, aclocal.m4, configure, configure.in:
* configure.in: 4.0.99k10
Harlan Stenn [Mon, 16 Oct 2000 23:53:57 +0000 (23:53 -0000)]
ChangeLog, driver35.htm, refclock_pcf.c:
* ntpd/refclock_pcf.c (pcf_start):
* html/driver35.htm:
The radio clock transmits 69 bits with a period of 2.5
milliseconds per bit. Thus the driver now sets the default
calibration offset to 0.1725 (69 * 2.5 = 172.5).
Its now possible to disable the check of the radio clock's
synchronisation status bit. Several users requested this option.
From: Andreas Voegele <andreas.voegele@gmx.de>
Harlan Stenn [Sun, 15 Oct 2000 05:47:38 +0000 (05:47 -0000)]
Many files:
* ntpq/ntpq_ops.c (dopeers): Daev didn't like the patch to show
the units on the times...
* ntpdc/ntpdc_ops.c (doset): SYS_FLAG_PPS cleanup
* ntpd/refclock_wwv.c (wwv_newchan): Update the peer refid if
we're talking to a stratum 0 source
* ntpd/refclock_trak.c: Needs PPS
* ntpd/refclock_oncore.c: Disable for now
* ntpd/refclock_mx4200.c: Needs PPSAPI, not PPS
Header cleanup. PPS interface cleanup.
Process sentences with a switch
Cleanup and sanity checks
* ntpd/refclock_datum.c: header cleanup, light body cleanup
* ntpd/refclock_conf.c: CLOCK_TRAK needs PPS
MX4200 needs PPSAPI, not PPS
Disable ONCORE for now
* ntpd/refclock_bancomm.c: Surgery
* ntpd/refclock_atom.c: Cleanup
(atom_control): added
(atom_ppsapi): added
* ntpd/ntp_request.c (setclr_flags): SYS_FLAG_PPS cleanup
* ntpd/ntp_refclock.c: stropts.h back in in TTYCLK and
HAVE_SYS_CLKDEFS_H
Get ntp_syscall if KERNEL_PLL
Define cal_enable
(refclock_receive): Cleanup
(refclock_control): sanity check procptr
* ntpd/ntp_proto.c (init_proto): pps_enable
(proto_config): Turn on/off PPS discipline
* ntpd/ntp_loopfilter.c: pps_enable
(local_clock): record_loop_stats() if !ntp_enable
(local_clock): Turn off PPS if it's not enabled
Other cleanup/fixes
* ntpd/ntp_config.c: pps and calibrate keywords. Initialize
pps_assert to 0, not 1 (swap assert/clear?)
* include/ntpd.h: We have pll_status if KERNEL_PLL
Added pps_enable and cal_enable
* include/ntp_request.h (SYS_FLAG_PPS): Renamed from
SYS_FLAG_AUTHENTICATE
* include/ntp.h (PROTO_PPS): Added
(PROTO_CAL): Added
From: Dave Mills
ChangeLog, ntp_refclock.h, iosignal.c, ntp_refclock.c, ntpq_ops.c:
* include/ntp_refclock.h (stropts.h, sys/clkdefs.h): Harmful and
useless file include's turned off.
* libntp/iosignal.c (netinet/in.h, sys/sockio.h): Duplicate file
include's turned off.
* ntpd/ntp_refclock.c (ntp_tty.h): File included.
(refclock_open, refclock_ioctl): Use `TTY' from ntp_tty.h.
* ntpd/refclock_atom.c: Grab a few headers regardless; if we don't
CLOCK_ATOM we provide a stub pps_sample() routine wo the WHARTON
can be compiled/used.
* ntpq/ntpq_ops.c (dopeers, doopeers): Print the units for
each column header.
Tue Sep 12 16:25:51 2000 Philippe De Muyter <phdm@macqel.be>
ChangeLog, refclock_atom.c:
* ntpd/refclock_atom.c (atom_start): Lose "temp", because we now
initially either CAPTUREASSERT or CAPTURECLEAR.
(atom_pps): pps_info_t is our friend. Update comments to reflect
reality. DTRT with pps_info. Do some overflow checks.
From: Dave Mills.
ChangeLog, aclocal.m4, configure, configure.in:
* configure.in: Much improved Solaris patch-level check for the
FLL bug test.
From: Marc.Brett@westgeo.com
ChangeLog, refclock_atom.c, refclock_oncore.c:
* ntpd/refclock_oncore.c (oncore_get_timestamp): Prind debug
messages being aware of HAVE_STRUCT_TIMESPEC.
* ntpd/refclock_atom.c: Have pps_params tag along in the ppsunit
structure, where it really belongs.
(atom_pps): Use PPS_CAPTURE{ASSERT,CLEAR}
From: Dave Mills.
ChangeLog, Makefile.in, aclocal.m4, configure, configure.in:
* configure.in: ac_cv_atom_ok, depends on HAVE_PPSAPI.
I notice the PARSE clocks require ATOM. Could be interesting...
ChangeLog, ntp_refclock.c, refclock_atom.c:
* ntpd/refclock_atom.c: Use the new ppsunit. Cleanup and improve
documentation.
* ntpd/ntp_refclock.c (refclock_sample): Don't accumulate
variance.
From Dave Mills
ChangeLog, driver22.htm, refclock_atom.c:
* html/driver22.htm: Update the docs.
* ntpd/refclock_atom.c (pps_sample): Make it more visible.
From Dave Mills.
Harlan Stenn [Thu, 31 Aug 2000 23:42:44 +0000 (23:42 -0000)]
ChangeLog, refclock_atom.c:
* ntpd/refclock_atom.c (atom_start): Open the device if it hasn't
been opened already.
From Dave Mills.
* ntpd/refclock_atom.c (atom_shutdown): Typo
From Dave Mills
* ntpd/refclock_atom.c: Header cleanup Comment cleanup. Lose the
TTYCLK stuff. Convert to PPSAPI.
* ntpd/ntp_refclock.c (refclock_newpeer): Move refclock_unpeer().
From: Dave Mills
Harlan Stenn [Thu, 31 Aug 2000 18:14:46 +0000 (18:14 -0000)]
Many files:
* configure.in: 4.0.99k8
* configure.in: The PPSAPI headers use "inline", so require a STDC
compiler.
* ntpd/refclock_atom.c (atom_shutdown): Typo
From Dave Mills
Harlan Stenn [Sun, 20 Aug 2000 20:08:26 +0000 (20:08 -0000)]
Many files:
* util/ntptime.c (main): Report TAI stuff
* ntpq/ntpq.c: CS_COMPLIANCE/CS_JITTER cleanup
* ntpd/ntp_loopfilter.c (local_clock): sys_error/sys_jitter cleanup.
kernel PPL cleanup.
* ntpd/ntp_crypto.c: Check NTP_API if we're doing KERNEL_PLL so we
can get the TAI stuff.
* ntpd/ntp_control.c: CS_COMPLIANCE now reports "error" instead of
"jitter". CS_JITTER now reports jitter.
* include/ntpd.h: Added sys_jitter
* include/ntp_control.h (CS_JITTER): Added
From: Dave Mills
Harlan Stenn [Sun, 20 Aug 2000 19:49:36 +0000 (19:49 -0000)]
ChangeLog, configure, cmd_args.c:
* ntpd/cmd_args.c (getCmdOpts): Crack -N at pre-scan, as we do the
priority wiggle before the final scan.
From: Tom Smith <smith@cag.lkg.dec.com>
We might do better to move the priority wiggle to after the final
scan. Especially if we want to permit command-line options to
have decent control over the priority. When we rewrite the config
file stuff we might go to a multi-scan to solve some of these
problems.
Harlan Stenn [Fri, 18 Aug 2000 01:33:38 +0000 (01:33 -0000)]
ChangeLog, aclocal.m4, config.h.in, configure, configure.in:
* configure.in (ac_cv_struct_ntptimeval): Lose the TAI check - we
don't need it since we can check NTP_API. Re-hack the generated
configure script.
Harlan Stenn [Sun, 13 Aug 2000 23:33:06 +0000 (23:33 -0000)]
ChangeLog, ntp_crypto.c, ntp-genkeys.c:
* ntpd/ntp_crypto.c (crypto_rsa): Now that we're using
NTP_KEYSDIR, make sure there is a '/ between the dir and the file.
* util/ntp-genkeys.c (main): More small steps...
Harlan Stenn [Sat, 12 Aug 2000 05:16:02 +0000 (05:16 -0000)]
ChangeLog, aclocal.m4, configure, configure.in, ntp_loopfilter.c:
* configure.in: 99k5
* ntpd/ntp_loopfilter.c (local_clock): Change 0. to 0 in a couple
of places.
From Dave Mills
Harlan Stenn [Sun, 6 Aug 2000 23:29:22 +0000 (23:29 -0000)]
ChangeLog, Makefile.am, Makefile.in:
* ntpd/Makefile.am (check-local): Use test in favor of [
ChangeLog, check_y2k.c:
* ntpd/check_y2k.c: Make debug definition match ntpd.h's declaration
Harlan Stenn [Fri, 4 Aug 2000 05:31:50 +0000 (05:31 -0000)]
Many files:
* ntpd/ntp_proto.c (peer_xmit): Crypto cleanup
* ntpd/ntp_crypto.c: Cleanup
* ntpd/ntp_control.c: Join the club
* ntpd/ntp_config.c: Call crypto_config() instead; we got rid of
crypto_flags.
* include/ntp_crypto.h (CRYPTO_FLAG_ENAB): New crypto flags, rework
* include/ntp_control.h (CS_FLAGS): Wiggle in.
* include/ntp.h: Added crypto peer status to struct peer
From Dave Mills
Harlan Stenn [Tue, 1 Aug 2000 03:01:34 +0000 (03:01 -0000)]
ChangeLog, ntp-genkeys.c:
* util/ntp-genkeys.c (main): Use strdup on the tokens returned
from ntp_config...
* util/ntp-genkeys.c (crypto_config): Fix a typo...
* util/ntp-genkeys.c (crypto_config): Even more...
Harlan Stenn [Tue, 1 Aug 2000 02:32:26 +0000 (02:32 -0000)]
ChangeLog, ntp_config.c, ntp-genkeys.c, ntp_config.h:
* include/ntp_config.h:
* ntpd/ntp_config.c: Move a whack of #defines to ntp_config.h so
ntp-genkeys.c can see them, too.
Many files:
* configure.in: 4.0.99k4
* util/ntp-genkeys.c: Start hacking for new functionality.
* include/Makefile.am (noinst_HEADERS): Added ntp_cmdargs.h and
ntp_config.h .
* ntpd/ntp_config.c: Grab ntp_cmdargs.h. Make some new globals
(ugh), move ntpd-specific variables and code to cmd_args.c .
* ntpd/cmd_args.c: Move command argument processing functions from
ntp_config.c to this file.
* ntpd/Makefile.am (ntpd_SOURCES): Added cmd_args.c
* include/ntpd.h: Move getstartup() to ntp_cmdargs.h
* include/ntp_cmdargs.h: New file
Begin the hacking fest to make it easier for ntp-genkeys to use
ntpd's config processing code. I really hope this is the lesser
of the evils...