This is the mail archive of the
libc-hacker@cygnus.com
mailing list for the glibc project.
Re: glibc-2.0.7: patch for ntp_{get,adj}time
- To: Ulrich Drepper <drepper@cygnus.com>, drepper@cygnus.com, libc-alpha@cygnus.com
- Subject: Re: glibc-2.0.7: patch for ntp_{get,adj}time
- From: "Ulrich Windl" <ulrich.windl@rz.uni-regensburg.de>
- Date: Fri, 8 Jan 1999 08:13:38 +0100
- Cc: libc-alpha@cygnus.com
- Organization: Universitaet Regensburg, Klinikum
- References: "Ulrich Windl"'s message of "Thu, 7 Jan 1999 11:42:46 +0100"
On 7 Jan 99, at 11:11, Ulrich Drepper wrote:
> "Ulrich Windl" <ulrich.windl@rz.uni-regensburg.de> writes:
>
> > I'm not a glibc guru, but I've tried to make a patch to implement the
> > missing functions ntp_gettime() and ntp_adjtime() that some users
> > complain about. Maybe you can apply the glibc guidelines where
> > necessary. Especially I'm no specialist in writing texinfo
> > documentation...
>
> Thanks, I've added the patch, a little bit modified though.
>
> But I have a problem with it. On Solaris 7 ntp_adjtime is defined like this:
>
> int ntp_adjtime(struct timex *);
OOPS, seems to be a bug somewhere: xntpd actually uses the sequence
ntv.modes = MOD_FREQUENCY;
ntv.freq = freq + drift_comp;
if (ntp_adjtime(&ntv) < 0)
so that I guess Solaris and you are right. But I thought that I've
copied the prototype from Dave Mills' kernel simulator. I'll have to
re-check over the weekend. Could also be that my mind messed up
things...
>
> So the question is: where does the amode argument in your version come
> from? I'm no expert in all this NTP stuff so I don't dare to judge
> about this.
If you'd like to fix it, remove the "amode" from the parameter list,
also the assignment, and fix the documentation, or wait 'til Ive
tried the same.
>
> If anybody reading this knows more about NTP please talk to me.
Regards,
Ulrich WIndl