From owner-freebsd-current Mon Feb 25 12:27:33 2002 Delivered-To: freebsd-current@freebsd.org Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by hub.freebsd.org (Postfix) with ESMTP id 7568937B402; Mon, 25 Feb 2002 12:27:29 -0800 (PST) Received: (from dillon@localhost) by apollo.backplane.com (8.11.6/8.9.1) id g1PKRKU52902; Mon, 25 Feb 2002 12:27:20 -0800 (PST) (envelope-from dillon) Date: Mon, 25 Feb 2002 12:27:20 -0800 (PST) From: Matthew Dillon Message-Id: <200202252027.g1PKRKU52902@apollo.backplane.com> To: Bruce Evans Cc: Terry Lambert , Alfred Perlstein , Bosko Milekic , Seigo Tanimura , , John Baldwin Subject: Re: Patch for critical_enter()/critical_exit() & interrupt assembly revamp, please review! References: <20020225164356.Q39518-100000@gamplex.bde.org> 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 Unless an unforseen problem arises, I am going to commit this tomorrow and then start working on a cleanup patch. I have decided to keep the sysctl instrumentation intact for the moment so people who experience panics or lockups can turn it off to see whether that was the cause or not. The cleanup patch will deal with moving the critical_*() functions from MI to MD, inlining, and the removal of the (old) CRITICAL_FORK and (new) MACHINE_CRITICAL_ENTER hacks. I'll probably wind up adding (i.e. /usr/src/sys//include/critical.h) and for i386 sys/i386/i386/critical.c to hold unpend() and other support routines. I've looked at cleaning up cpu_critical_enter() & exit but its use pollutes a number of MI source files: kern/kern_ktr.c, kern/subr_trap.c, and kern/subr_witness.c are all misusing the functions. If these functions can safely be changed to use critical_enter() and critical_exit() I will rename the i386's cpu_critical*() functions into intr_disable() and intr_restore() and then use the new names for internal i386 use. Is there any reason why the above uses of cpu_critical*() cannot be changed to use standard critical*()? I believe we *always* have a curthread structure to play with so it should just work. -Matt To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message