From owner-freebsd-arch Fri Mar 23 18:27:24 2001 Delivered-To: freebsd-arch@freebsd.org Received: from meow.osd.bsdi.com (meow.osd.bsdi.com [204.216.28.88]) by hub.freebsd.org (Postfix) with ESMTP id 93F8037B732 for ; Fri, 23 Mar 2001 18:27:13 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: from laptop.baldwin.cx (john@jhb-laptop.osd.bsdi.com [204.216.28.241]) by meow.osd.bsdi.com (8.11.2/8.11.2) with ESMTP id f2O2Q3G30932; Fri, 23 Mar 2001 18:26:03 -0800 (PST) (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: <200103232027.f2NKRS928064@arch20m.dellroad.org> Date: Fri, 23 Mar 2001 18:26:12 -0800 (PST) From: John Baldwin To: Archie Cobbs Subject: Re: Critical Regions Round II Cc: arch@FreeBSD.org Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 23-Mar-01 Archie Cobbs wrote: > John Baldwin writes: >> Also, this entire API was forced out into MI code. After the discussion on >> the mailing list I propose the following that will hopefully make everyone >> happy: >> >> disable_intr() - x86 / ia64 only, just clears the IF or psr.i bit, and is >> a MD function >> enable_intr() - x86 / ia64 only, just sets the IF or psr.i bit, and is a >> MD function > > Apologies in advance if I'm missing something obvious.. > > Shouldn't these be, e.g., > > i386_disable_intr(), i386_enable_intr() > > and > > ia64_enable_intr(), ia64_disable_intr() > > That is, it seems like "machine dependent" has a strict meaning, > it means: specific to a single (one) architecture. Sticking all MD stuff under a ${MACHINE_ARCH}_* namespace might be an interesting project in the future, but it wouldn't be a small undertaking. > Or are we expecting to have code that looks like this: > > #if defined(__i386__) || defined(__ia64__) > disable_intr() > #endif > > ?? No, this code should not be used outside of sys/${MACHINE_ARCH}, which is mostly how things were (aside from broken things like the joy driver) before SMPng. -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message