From owner-freebsd-arch Wed Jan 22 3:48: 3 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7A14A37B401 for ; Wed, 22 Jan 2003 03:48:01 -0800 (PST) Received: from mail.qubesoft.com (gate.qubesoft.com [217.169.36.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F69943ED8 for ; Wed, 22 Jan 2003 03:48:00 -0800 (PST) (envelope-from dfr@nlsystems.com) Received: from bluebottle.qubesoft.com (bluebottle.qubesoft.com [192.168.1.2]) by mail.qubesoft.com (8.12.6/8.12.6) with ESMTP id h0MBlpBs022642; Wed, 22 Jan 2003 11:47:51 GMT (envelope-from dfr@nlsystems.com) Received: from builder02.qubesoft.com (builder02.qubesoft.com [192.168.1.8]) by bluebottle.qubesoft.com (8.12.6/8.12.6) with ESMTP id h0MBllt8025459; Wed, 22 Jan 2003 11:47:47 GMT (envelope-from dfr@nlsystems.com) Subject: Re: the mythical syscons redesign document ( was Re: Porting wscons ) From: Doug Rabson To: "Pedro F. Giffuni" Cc: Marcel Moolenaar , arch@FreeBSD.ORG In-Reply-To: <20030122010246.52789.qmail@web13404.mail.yahoo.com> References: <20030122010246.52789.qmail@web13404.mail.yahoo.com> Content-Type: text/plain Organization: Message-Id: <1043236066.28124.6.camel@builder02.qubesoft.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.0 Date: 22 Jan 2003 11:47:46 +0000 Content-Transfer-Encoding: 7bit X-Spam-Status: No, hits=-4.7 required=5.0 tests=IN_REP_TO,REFERENCES,SPAM_PHRASE_00_01 version=2.41 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 2003-01-22 at 01:02, Pedro F. Giffuni wrote: > --- Marcel Moolenaar ha scritto: > > On Tue, Jan 21, 2003 at 05:47:13AM +0100, Pedro F. > > Giffuni wrote: > > > OK, I found it: > > > > > > > > > http://www.freebsd.org/cgi/getmsg.cgi?fetch=302402+322879+/usr/local/www/db/text/1998/freebsd-current/19980802.freebsd-current > > > > It makes perfect sense to me why this hasn't been > > implemented. Not > > because it's wrong, but because it's impractical. > > Ahem... the original document is from 1993. By those > years it was probably ahead of it's time :-). I think > there is one important thing that must be learned: > > What ever is done nowadays, must be based on an OO > design. > > In support to this, Newbus (which wasn't even a plan > in those years) is our friend. > I propose the following approach: > > 1) properly newbussify all the devices used by our > console. > 2) newbussify syscons (it doesn't use methods, does > it?) and clean the PC specifics as much as possible. > 3) port and newbussify wscons. > 4) find a way to run the both at the same time. The main sticking point for this stuff is that console is needed before the device tree is probed. I think the right approach will be to define a set of interfaces for the video console and then implement those interfaces using the lower-level kobj system. This allows you to put together a working console output system before the rest of the system is up and running. You can even use kobj before malloc is working if you are careful. I once had a prototype system on alpha which used kobj for all the busspace i/o primitives. It worked pretty well with kobj but I later changed it to use fixed arrays of function pointers because there was some interest in porting it over to 4.x which didn't have kobj at the time. I always preferred the kobj version since it had a nice stable ABI. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message