From owner-freebsd-arch@FreeBSD.ORG Mon Nov 8 20:27:34 2004 Return-Path: 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 D000D16A4CE; Mon, 8 Nov 2004 20:27:34 +0000 (GMT) Received: from freebee.digiware.nl (dsl439.iae.nl [212.61.63.187]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5F8AE43D2F; Mon, 8 Nov 2004 20:27:33 +0000 (GMT) (envelope-from wjw@withagen.nl) Received: from [212.61.27.71] (dual.digiware.nl [212.61.27.71]) by freebee.digiware.nl (8.12.10/8.12.10) with ESMTP id iA8KRV5p056598; Mon, 8 Nov 2004 21:27:31 +0100 (CET) (envelope-from wjw@withagen.nl) Message-ID: <418FD6B3.4040600@withagen.nl> Date: Mon, 08 Nov 2004 21:27:31 +0100 From: Willem Jan Withagen User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.2) Gecko/20040804 Netscape/7.2 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 To: John Baldwin References: <418AB176.9030604@withagen.nl> <200411051400.34684.jhb@FreeBSD.org> <418BE3D2.2030205@withagen.nl> <200411081353.15394.jhb@FreeBSD.org> In-Reply-To: <200411081353.15394.jhb@FreeBSD.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-arch@FreeBSD.org Subject: Re: Booting questions .... X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Nov 2004 20:27:34 -0000 John Baldwin wrote: [All about getting a flat memoryspace] >>>>Next is then which ranges are valid to test, and then things really start >>>>to get complicated and arch dependant. Which is why I ended up in >>>>machdep.c right after the setting up of the memory ranges. >>> >>>Heh, the above memory mapping is also i386 specific. Alpha only has a >>>small bit of memory mapped in the loader, same with sparc64, etc. >> >>Ehhhh, again more reasons to put this in the kernel, or something that >>closely resembles a kernel. > > > Well, part of the problem there is that the early kernel code is all MD > anyway. I think your best bet really is to write your own mini-kernel that > the loader can load to do this, but it will require MD stubs for early > bootstrapping as well as some kind of API for mapping a page so you can test > it and then unmap it, which is required for x86 machines with > 4GB of RAM > for example. I would start simple, and forget about PAE, since I do not have a PAE machine... Simple 1386, and amd64-smp is all I got. Then I'd rather look at other architectures, then look at PAE. If ever I get this far. Can you give me some hints from the current modules/source-files on i386 I would at least need to get somewhere. Because that would be the way I'd go: See if I can rip enough from the regular kernel to be able to build the mini-kernel. And give the way mi_startup works that would be a very nice/simple way to keep loading modules until there is enough to get the work done. Did anybody write a routine that "dumps" the module list before mi_startup start to work on it??? Or would that be my first assignment :) I'll start by copying my own sys-tree so work does not get overwritten by daily cvsup. --WjW