From owner-cvs-all Sat Feb 14 04:49:13 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id EAA15481 for cvs-all-outgoing; Sat, 14 Feb 1998 04:49:13 -0800 (PST) (envelope-from owner-cvs-all@FreeBSD.ORG) Received: from spinner.netplex.com.au (spinner.netplex.com.au [202.12.86.3]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id EAA15434; Sat, 14 Feb 1998 04:47:54 -0800 (PST) (envelope-from peter@netplex.com.au) Received: from spinner.netplex.com.au (localhost [127.0.0.1]) by spinner.netplex.com.au (8.8.8/8.8.8/Spinner) with ESMTP id UAA03995; Sat, 14 Feb 1998 20:46:42 +0800 (WST) (envelope-from peter@spinner.netplex.com.au) Message-Id: <199802141246.UAA03995@spinner.netplex.com.au> X-Mailer: exmh version 2.0zeta 7/24/97 To: Mike Smith cc: Ollivier Robert , core@FreeBSD.ORG, committers@FreeBSD.ORG Subject: Re: wfd block major number reassignment from 24 to 1 In-reply-to: Your message of "Sat, 14 Feb 1998 04:08:53 PST." <199802141208.EAA21988@dingo.cdrom.com> Content-Transfer-Encoding: quoted-printable Date: Sat, 14 Feb 1998 20:46:41 +0800 From: Peter Wemm Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk Mike Smith wrote: > > According to Mike Smith: > > > They have certainly addressed just about everything that I recall u= s = > > > ever having discussed as an issue, and a number that hadn't occurre= d to = > > > me. > > = > > Can we have a 3-stage bootloader *without* encoding the blocks number= in > > the first stage (=E0 la SunOS / Lilo) ? > = > I've already made my opinions on this known; I haven't heard much = > comment elsewhere, but I doubt that there would be many takers for such= = > an animal. (ie. yes, I think we can.) GRUB (Grand Unified Boot Loader) already does it, so I don't see why we = couldn't. :-) The simplest way of getting this up and running is: - take current boot code - chop out all unnecessary code (eg: kernel setup, memory sizing, etc, et= c) - have resulting "lightweight" loader actually load the real loader at so= me fixed address, and jump to it. "real" loader does all the kernel = bootstrap, memory sizing, ELF symbols, run-time linking, userconfig, et= c. let 'ld' and tools do all the hard work and produce a /boot binary = tailored specifically for the task. You don't need nlist(), symbols, a.out or elf support etc. It'd just be a flat file linked at a specifi= c address. Problem: /boot gets munched, you want to specify an alternate root = partition or /boot.old or something. Solution: Leave enough of the keyboard parsing code so that if (say) the= = ALT key is held down during boot or (like win95) the F8 key was pressed, = then stop and put up a simple prompter to specify an alternate path/ parition/bios drive/etc. Kinda like a cut-down version of the kernel = selector. If /boot wasn't available, then it could try /boot.old = automatically, or just put up the requester. That way, you don't get = seperate boot1 and boot2 prompts, and don't delay while the 7K loader doe= s = it's thing. It should be no real drama to make a 7K stage-2 loader for a specially = prepared /boot image that can still be controlled by the keyboard etc. Dos booting is unaffected. dosboot.exe would still load the "full" boot = code and do it's thing. It doesn't have size problems. Net booting is more tricky. The netboot code for the eproms would need t= o have the same diet applied, except that it'd load /netboot instead, which= = could be an alternative compilation of the stage3 code. Alternatively, /boot could simply be compiled to start up under a UFS or NFS root = environment. All of the options now available from the Boot: prompt would be provided = by the 3rd stage kernel loader, except that it would no longer have the = dreaded space problem. Sounds easy, eh? Well, the devil is in the details.. That's why nobody = has done it for FreeBSD (and because many unix programmers don't like = working at real-mode 16-bit bios level :-). Cheers, -Peter -- Peter Wemm Netplex Consulting To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message