From owner-freebsd-current Sun Feb 16 23: 6: 3 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0771737B401; Sun, 16 Feb 2003 23:06:02 -0800 (PST) Received: from canning.wemm.org (canning.wemm.org [192.203.228.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9624243F3F; Sun, 16 Feb 2003 23:06:01 -0800 (PST) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by canning.wemm.org (Postfix) with ESMTP id 78E612A89E; Sun, 16 Feb 2003 23:06:01 -0800 (PST) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.5 07/13/2001 with nmh-1.0.4 To: "M. Warner Losh" Cc: nyan@jp.FreeBSD.org, sos@FreeBSD.ORG, current@FreeBSD.ORG, mdodd@FreeBSD.ORG Subject: Re: The cbus driver for pc98 In-Reply-To: <20030216.235014.111547234.imp@bsdimp.com> Date: Sun, 16 Feb 2003 23:06:01 -0800 From: Peter Wemm Message-Id: <20030217070601.78E612A89E@canning.wemm.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 "M. Warner Losh" wrote: > In message: <20030209.224741.71137260.nyan@jp.FreeBSD.org> > Takahashi Yoshihiro writes: > : I have made the cbus driver for pc98 based on i386 isa driver. This > : completely removes that PC98 depends on isa driver and also corrects > : directory layouts (pc98/i386 -> pc98/pc98 and pc98/pc98 -> pc98/cbus). > : > : The full patch can get from > : http://home.jp.FreeBSD.org/~nyan/patches/cbus.diff.gz > : > : Soeren, please review the ata part. > : http://home.jp.FreeBSD.org/~nyan/patches/cbus-ata.diff.gz > : > : Warner, please review the oldcard part. > : http://home.jp.FreeBSD.org/~nyan/patches/cbus-pccard.diff.gz > : > : > : If it has no problem, I'll commit after required repository copy. > > Please excuse my tardiness in replying to this review request. I've > just finished a large release at work that was consuming much of my > time. > > I do not like this. It seems to take too many files and just do a > simple s/isa/cbus/g on them. However, I'm not sure that we want to do > that with so many files when the majority of them are very close to > being able to just add a second module line. I think it would be > better to implement cbus as an 'isa bus subclass'. cbus is an > isa-like bus in many respects from a programming point of view. > Copying everything is not the right way to approach this problem, > imho. It would be better if the cbus bus implemented the isa routines > and accepted that 'isa' is a bit if a misnomer. I can understand if you do not like to call your cbus hardware "ISA" devices, but also consider that on most pc-at hardware there are no "ISA" devices either. Things like the floppy controller, keyboard controller, counter/timer, rtc, etc etc are all on motherboard busses. Many are on things like X-bus, v-link, or other custom "quick and dirty" host busses. If we started i386/x-bus/* and i386/v-link/* etc then things would get ugly very quickly. Personally, I would rather live with #ifdef PC98 than to have a duplicate set of isa/* and i386/* files that are nearly identical except for include file paths, #ifdef PC98 and s/isa/cbus/. I'm sure there are other ways to improve the situation without having to resort to this mass duplication of code. Cheers, -Peter -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message