Subject: Re: Which preboot-loader?
To: None <tech-ports@NetBSD.ORG>
From: Andrew Cagney <firstname.lastname@example.org>
Date: 04/21/1996 18:30:07
>> NetBSD has a number of kernel loaders (the program that gets loaded [...]
>> which one best represents what the loader should look like?
der Mouse wrote:
> I'm not sure the question even makes sense, since in many cases the
> loader is constrained by port-specific issues.
Sorry, I'll try to expand a little.
To load a kernel into memory and start it, the loader would normally:
1. prompt the user for the kernel (plus options)
2. read the specified kernel from the corresponding
Thinking of things in an abstract way, each of the above can be broken
into several parts:
1.1 the prompting which could be portable
1.2 a host specific console I/O that 1.1 would
2.1 generic code to open a file system and read
2.2 host specific(?) code that can read/write
blocks from a device that 2.1 would use
2.3 the horrible muck that takes the kernel
file and jumps to it. This would be using
2.1 to read the kernel in.
(Ignoring all the detail that has been left out :-)
Looking at some of the loaders I find that they are starting to use
this libsa (standalone?) which contains code for reading kernels from
file systems. The target then simply provides the read/write
functions that libsa needs.
So, to rephrase my question a bit, which of the loaders in NetBSD has
the closest model to what I've described above?