From owner-freebsd-arch@FreeBSD.ORG Tue May 25 12:49:39 2010 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3EC461065674; Tue, 25 May 2010 12:49:39 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 119428FC0A; Tue, 25 May 2010 12:49:39 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id B7C9F46B8F; Tue, 25 May 2010 08:49:38 -0400 (EDT) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPA id 3EBF68A027; Tue, 25 May 2010 08:49:36 -0400 (EDT) From: John Baldwin To: freebsd-arch@freebsd.org Date: Mon, 24 May 2010 15:30:05 -0400 User-Agent: KMail/1.12.1 (FreeBSD/7.3-CBSD-20100217; KDE/4.3.1; amd64; ; ) References: <4BFAA1F3.1070206@FreeBSD.org> In-Reply-To: <4BFAA1F3.1070206@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="koi8-r" Content-Transfer-Encoding: 7bit Message-Id: <201005241530.05116.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0.1 (bigwig.baldwin.cx); Tue, 25 May 2010 08:49:36 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.95.1 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=AWL,BAYES_00, DATE_IN_PAST_12_24 autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on bigwig.baldwin.cx Cc: Alexander Motin Subject: Re: Event timers X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 May 2010 12:49:39 -0000 On Monday 24 May 2010 11:57:39 am Alexander Motin wrote: > Hi. > > You should agree that event timers code we have now (hardclock, > statclock and profclock source) is real mess. The code is completely > machine-dependent, many times duplicated (I have found 4 or 5 equal > implementations and many more trivial ones), very tangled and > inflexible. While it is acceptable for some platforms with single > interrupt source running on hz, x86 with it's many different timers > definitely doesn't look good. So I've decided to clean it. > > I have defined several points on that way: > 1*. clean low-level timer drivers from unrelated stuff, > 2*. make some common code machine-independent, > 3. write common driver API for event timers (alike to one we have now > for time counters) to make adding more drivers possible, > 4. add support for HPET as event timer in addition to time counter, > 5. add support for timers in one-shot mode (LAPIC and HPET). Have you looked at the dynamic ticks patches on hackers@? Those already include changes for 5), although he currently only has support for LAPIC and is working on adding HPET support. -- John Baldwin