From owner-freebsd-hackers Sun Feb 18 13:34:37 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from siri.nordier.com (c2-dbn-60.dial-up.net [196.34.155.188]) by hub.freebsd.org (Postfix) with ESMTP id 6112837B4EC for ; Sun, 18 Feb 2001 13:34:29 -0800 (PST) Received: (from rnordier@localhost) by siri.nordier.com (8.9.3/8.6.12) id XAA15802; Sun, 18 Feb 2001 23:36:24 +0200 (SAST) From: Robert Nordier Message-Id: <200102182136.XAA15802@siri.nordier.com> Subject: Re: boot1 changes and etherboot support In-Reply-To: <200102181758.f1IHwmB27757@iguana.aciri.org> from Luigi Rizzo at "Feb 18, 2001 9:58:48 am" To: rizzo@aciri.org (Luigi Rizzo) Date: Sun, 18 Feb 2001 23:36:24 +0200 (SAST) Cc: hackers@freebsd.org, rnordier@nordier.com X-Mailer: ELM [version 2.4ME+ PL43 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Luigi Rizzo wrote: > > > + put some conditional-compilation code in boot1.s > > > + have a separate file, say bootrom.s, maybe in the same directory > > > as the existing boot1 > > > + pass the modified code to the etherboot people so they can include > > > in their source tree. > > > > > > in all sincerity i'd love to have this code in the FreeBSD source tree > > > rather than have to resort to some external repository. > > > > My preference would be for a separate file in a separate directory, > > more or less similar to cdldr and pxeldr; I'd be least keen on handling > > this with conditional-compilation. > > ok.. do you mind then if i follow your advice and create /sys/i386/romldr/ > and put there the modified boot1, makefile etc ? > There has been no other feedback so i think most other people is neutral. Seems good to me. > On a separate issue, and for picobsd purposes, it would be very > convenient to have yet another boot sector type that would just > take an ELF kernel appended to it, load into memory and start it. > I suppose this would be a variant of boot2, but do you have any > idea on how complex would it be to write such a beast ? I have a generic boot1, that would just about do this. Instead of understanding filesystems or file formats, it works off an embedded list of block address, block count pairs. I've used the same code to boot a.out and ELF kernels off ufs, fat, and iso9660 file systems; but it does need an installation utility rather than just dd. On the other hand, to create exactly what you had in mind isn't all that much work. A sort of combination of logic from boot1.s and btx/btxldr.s (which parses ELF) would do the job in pure assembly language; otherwise just stripping most of the functionality from boot2 should work in C (and would be similar to "rawboot" that phk did using the old aout bootblocks). -- Robert Nordier rnordier@nordier.com // Le monde est plein de fous, et qui n'en veut pas voir rnordier@FreeBSD.org // Doit se tenir tout seul, et casser son miroir. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message