Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Sep 1998 22:09:01 +0200 (SAT)
From:      John Hay <jhay@mikom.csir.co.za>
To:        bde@zeta.org.au (Bruce Evans)
Cc:        current@FreeBSD.ORG
Subject:   Re: Death by SIGXCPU (problems with our clock code)
Message-ID:  <199809172009.WAA15605@zibbi.mikom.csir.co.za>
In-Reply-To: <199809171616.CAA19641@godzilla.zeta.org.au> from Bruce Evans at "Sep 18, 98 02:16:18 am"

next in thread | previous in thread | raw e-mail | index | archive | help
> >So, do you have better test code that is available, or should I just use
> >Mike's? I would really also like to find out what the problem is, because
> >I have just about given up trying to get PPS working properly from sio
> >interrupts on 486 and SMP machines. On my two machines that use the 8254
> >for the timecounter I see forward jumps.
> 
> How big and consistent are the jumps?  microtime() was never designed to
> work when called from a fast interrupt handler.  It's interesting that it
> works worse than before.  It's fairly obvious why it doesn't - switching
> high-level timecounters is atomic, but the i8254 timecounter has internal
> state that is not switched atomically in clkintr().  This part of the
> problem should be easy to fix by adding a disable_intr()/enable_intr().

I'm not sure what the exact size is, I only have the values by which ntpd
stepped the time to get it right again. (which is the oposite of what the
error was and also ntpd might first have tried to slew it.)

The 486 seems to jump forward about 0.45 seconds a few times a week. The
0.45 is fairly consistant. The dual P5 machine jump forward about 0.85
seconds up to a few times a day. A few times 1.7 seconds.

Is it possible to lower the priority of the sio interrupts? To maybe
not configure them as fast interrupts? On the time servers the serial
ports are only used for the GPS and its PPS signal, so the baud rate is
low. Or is there maybe another way that I can get the time from a sio
interrupt handler?

Will disable_intr()/enable_intr() work on the SMP machines?

John
-- 
John Hay -- John.Hay@mikom.csir.co.za

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199809172009.WAA15605>