*BSD News Article 18176


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!agate!agate.berkeley.edu!cgd
From: cgd@erewhon.CS.Berkeley.EDU (Chris G. Demetriou)
Newsgroups: comp.os.386bsd.bugs
Subject: Re: kernel writes to user space
Date: 9 Jul 93 06:30:16
Organization: Kernel Hackers 'r' Us
Lines: 34
Message-ID: <CGD.93Jul9063016@erewhon.CS.Berkeley.EDU>
References: <20bfrm$le7@pdq.coe.montana.edu> <20qqgu$dj@werple.apana.org.au>
	<1993Jun30.022629.24466@uvm.edu> <C9GMzD.B6@veda.is>
	<1993Jul1.190202.17637@uvm.edu> <C9ICHs.py@veda.is>
NNTP-Posting-Host: erewhon.cs.berkeley.edu
In-reply-to: adam@veda.is's message of 1 Jul 93 22:44:02 GMT

there's a solution to this.

the convention is that "cpu foo" means that support for cpu
type foo is compiled into the kernel.

however, with the i386 and i486, it's tempting to say "cpu i386" etc.
which is a problem, because MACHINE is i386.

we use "cpu I386_CPU" (made it a bit long to prevent confusion),
and "cpu I486_CPU" to indicate "support for this type of CPU."

(unfortunately, this isn't an architecture where the architecture
type isn't the specific cpu type (e.g. hp300 vs. hp370).)


NetBSD/i386 detects the i386 vs. i486 CPU chip and, during
startup, if the machine you're running isn't supported by the
kernel you booted, will panic.

this means that the startup code has to handle all i386 and i486
cases, but that's ok, because it only gets run once...



there's little need to change convention to suit a f*cked up architecture.



chris
--
Chris G. Demetriou                                    cgd@cs.berkeley.edu

   "386bsd as depth first search: whenever you go to fix something you
       find that 3 more things are actually broken." -- Adam Glass