Subject: kern/19243: pps/ntp support is incomplete
To: None <>
From: None <>
List: netbsd-bugs
Date: 12/02/2002 14:22:56
>Number:         19243
>Category:       kern
>Synopsis:       pps/ntp support is incomplete
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Dec 02 14:23:00 PST 2002
>Originator:     Wolfgang Rupprecht
>Release:        NetBSD 1.6K
W S Rupprecht Computer Consulting, Fremont CA
System: NetBSD 1.6K NetBSD 1.6K (WSRCC_ATHLON) #13: Sat Nov 30 18:13:16 PST 2002 i386
Architecture: i386
Machine: i386
	<submitting this so that it won't get forgotten>

	Even though the distributed ntpd contains hooks for
	running a Motorola oncore m12 refclock,  the kernel pps
	support is incomplete and ntp rejects the oncore.

	cd /dev/
	ln -s gps ttyN
	ln -s oncore.serial.0 gps
	ln -s oncore.pps.0 gps

	# oncore-m12 sets the neg-edge at 0-second roll-over
	pps /dev/gps clear hardpps
	server prefer
	# end


	Dec  2 13:24:43 scoville ntpd[530]: precision = 9 usec
	Dec  2 13:24:43 scoville ntpd[530]: kernel time discipline status 0040
	Dec  2 13:24:43 scoville ntpd[530]: refclock_ioctl: time_pps_kcbind failed: Bad address
	Dec  2 13:24:43 scoville ntpd[530]: internal error: refclockio structure not found
	Dec  2 13:24:43 scoville ntpd[530]: configuration of failed

	The problem boils down to lack of kernel support for PPS_KC_HARDPPS.

	    from src/dist/ntp/ntpd/refclock_oncore.c:

	    if (time_pps_kcbind(instance->pps_h, PPS_KC_HARDPPS, i,
		 PPS_TSFMT_TSPEC) < 0) {

	This problem exists with both the old ntpd supplied in /usr/src and
	with the newer one in /usr/pkgsrc/net/ntp4 .