From owner-cvs-all Wed Nov 27 8:48:14 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A13037B404; Wed, 27 Nov 2002 08:48:13 -0800 (PST) Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 42BCD43EC2; Wed, 27 Nov 2002 08:48:12 -0800 (PST) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.3/8.12.3) with ESMTP id gARGmApk057445; Wed, 27 Nov 2002 09:48:11 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Wed, 27 Nov 2002 09:47:33 -0700 (MST) Message-Id: <20021127.094733.127703189.imp@bsdimp.com> To: dfr@nlsystems.com Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/sys rman.h src/sys/kern subr_rman.c From: "M. Warner Losh" In-Reply-To: <1038397024.8963.1.camel@builder02.qubesoft.com> References: <200211270355.gAR3tMQh036625@repoman.freebsd.org> <1038397024.8963.1.camel@builder02.qubesoft.com> X-Mailer: Mew version 2.1 on Emacs 21.2 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <1038397024.8963.1.camel@builder02.qubesoft.com> Doug Rabson writes: : On Wed, 2002-11-27 at 03:55, Warner Losh wrote: : > imp 2002/11/26 19:55:22 PST : > : > Modified files: : > sys/sys rman.h : > sys/kern subr_rman.c : > Log: : > Make the rman_{get,set}_* macros into real functions. The macros : > create an ABI that encodes offsets and sizes of structures into client : > drivers. The functions isolate the ABI from changes to the resource : > structure. Since these are used very rarely (once at startup), the : > speed penalty will be down in the noise. : > : > Also, add r_rid to the structure so that clients can save the 'rid' of : > the resource in the struct resource, plus accessor functions. Future : > additions to newbus will make use of this to present a simplified : > interface for resource specification. : : Can you move the structures out of the public header file now? I : originally wanted to hide the structures inside the implementation but : Garret wanted to allow direct access to the structures, I seem to : remember. The macros were a compromise. I'll try and see who/what it breaks. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message