From owner-freebsd-hackers Sat Sep 27 03:32:45 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id DAA17269 for hackers-outgoing; Sat, 27 Sep 1997 03:32:45 -0700 (PDT) Received: from bugs.us.dell.com (bugs.us.dell.com [143.166.169.147]) by hub.freebsd.org (8.8.7/8.8.7) with SMTP id DAA17143 for ; Sat, 27 Sep 1997 03:32:36 -0700 (PDT) Received: from ant.us.dell.com (ant.us.dell.com [198.64.66.34]) by bugs.us.dell.com (8.6.12/8.6.12) with SMTP id FAA25079 for ; Sat, 27 Sep 1997 05:32:05 -0500 Message-Id: <3.0.2.32.19970927053159.006c81e8@bugs.us.dell.com> X-Sender: tony@bugs.us.dell.com X-Mailer: QUALCOMM Windows Eudora Light Version 3.0.2 (32) Date: Sat, 27 Sep 1997 05:31:59 -0500 To: freebsd-hackers@FreeBSD.ORG From: Tony Overfield Subject: Re: Raise your hand if you know how to make this work. In-Reply-To: <199709250723.AAA09638@usr03.primenet.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk >> there is a function to do this for you >> it's rather trivial. >> check clock.c >> and see how the PCAUDIO device uses this to get itself >> called 16000 times per second.. At 07:23 AM 9/25/97 +0000, Terry Lambert wrote: >> > Note: this is about twice as fast as the standard clock can go; at >> > the highest divider, it's only capable of 8192 interrupts a second. >> >Jamil J. Weatherbee wrote >> If we are still talking about an 8253 I know you to be wrong here, the >> frequency varies like 1.9MHz/(1-65535). > >This information is from the Linux tier code and from the FreeBSD >clock divider code for the PC audio driver, and not from the chipset >documentation, so I'm prepared to be wrong (along with the comments >in both these drivers). I think Terry has confused the two "standard" timers. The "standard clock" timer, on IRQ0, is a 1.193 MHz clock with a programmable 16-bit divisor that can interrupt as fast as you would ever want it to. The "CMOS real-time clock" has a periodic interrupt, on IRQ8, based on a 32768 Hz clock with a small set of divisors that support interrupt rates between 2 Hz and 8192 Hz, inclusive, in powers of two.