From owner-freebsd-current Thu Mar 7 14:21: 3 2002 Delivered-To: freebsd-current@freebsd.org Received: from mail5.speakeasy.net (mail5.speakeasy.net [216.254.0.205]) by hub.freebsd.org (Postfix) with ESMTP id 0FB3137B405 for ; Thu, 7 Mar 2002 14:20:49 -0800 (PST) Received: (qmail 4129 invoked from network); 7 Mar 2002 22:20:48 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail5.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 7 Mar 2002 22:20:48 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.11.6/8.11.6) with ESMTP id g27MLBv07842; Thu, 7 Mar 2002 17:21:11 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <200203070318.g273IBB60433@apollo.backplane.com> Date: Thu, 07 Mar 2002 17:20:45 -0500 (EST) From: John Baldwin To: Matthew Dillon Subject: Re: Patch for critical_enter()/critical_exit() & interrupt assem Cc: Julian Elischer Cc: Julian Elischer , FreeBSD current users , Seigo Tanimura , Bosko Milekic , Alfred Perlstein , Terry Lambert , Bruce Evans , "Jeroen C.van Gelderen" Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 07-Mar-02 Matthew Dillon wrote: > >:Search for "paper John Baldwin" and find link 6: >: >:http://www.FreeBSD.org/cgi/getmsg.cgi?fetch=199282+204026+/usr/local/www/db/ >:text/2002/freebsd-arch/20020303.freebsd-arch >: >:The actual paper is at: >: http://www.FreeBSD.org/~jhb/smpng/design/article.{ps,pdf} >: >:-J >:-- >:Jeroen C. van Gelderen - jeroen@vangelderen.org > > Ok... I've read it. The sections on interrupts and critical sections > are fully compatible with my patch. The one section... basically > the last sentence of the last paragraph, is exactly the piece that > my patch cleans up and makes more flexible. Instead of requiring that > cpu_critical_*() always be used for the initial critical_enter() my > patch makes it optional, and for I386 I use that flexibility to allow > critical_*() to NOT have to call cpu_critical_*(). You seemed to have missed the entire part where we handle deferred preemptions in MI code in critical_exit(). The critical_enter/exit stuff really exists to support the preemption code and to get rid of the various FOO_NOSWITCH flags. I think it is ok to remove the linkage between critical_enter/exit and cpu_critical_* (possibly even renaming cpu_critical_* to a better name) and to allow arch's to optimize cpu_critical_* but leave critical_* as MI code. That's what I've asked for from the start and Jake even suggested it from the start. I'm still not comfortable with the optimiation, but changing the MI critical_* code is by far my biggest objection to the code. > -Matt > Matthew Dillon > -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message