[Prev][Next][Index][Thread]

Re: oskit how to boot



helen wrote:
> oskit how to boot?

Do you mean "How does one boot the kernel?"

Just take grub and use the "kernel" command to point to your kernel. 

> my oskit is in the redhat linux 7.2 with grub bootloader. for example 
> ,the hello kernel.oskit system how to boot,what is the course of 
> boot,then it starts the initialization of kernel hello.can some tell 
> me?

Well, Oskit produces kernels that conform to the multiboot
specification. (I will be resuming my pleas for information about how to
do the same in a week or two). 

Basically, through some ugly parameters passed to 'ld', the arcane and
undocumented linker from hell (Dante's Infernos is probably the best
documentation [er; that was a joke]), a fixed position ELF binary is
produced. It is then linked to the mboot (or something) library which
includes the crucial multiboot header which must be near the beginning
of the binary file. The kernels in Oskit have a fixed load adress of
0x100000 (the 1mb line) 

This much is done automaticaly by oskit build... You should also run
"strip" on "hello" which will reduce the size from around 200k to 50k
(which makes a big difference in performance when loading from flopy!!)
However, a stripped kernel is not [too] debugable; So develop unstriped
kernels and distribute their stripped versions.

Alright, once "hello" is placed in a convenient path on a boot media, it
is up to GRUB to find and load it. 

Grub is extremely flexable. the 486 I am typing this on has a 1.2 mb for
A: and the 1.44 is B; Using the MINIX boot monitor I can boot grub FROM
THE B DRIVE -- Which is most astonishing! Well, that's not too
important, just interesting trivia...

Grub does several things: 
1. It provides a boot monitor program through which the user can
experience a program that, because it has only reciently been taken over
by the GNU project, is still somewhat usable. 

2. It snoops the hardware and detects important inf0z. 

3. On command, it loads the kernel to the load address, "Populates" the
multiboot header with useful information, and 

Finally, it jumps to the kernel's entry point... This is the library
function _START_ which eventually calls "MAIN" which in turn prints
"Hello World". 

I WOULD REALLY LIKE TO KNOW WHAT EXACTLY START DOES AND HOW TO MAKE IT
WORK WITH ARBITRARY PROGRAMMING LANGUAGES!!!!!! Where in the 50 megs of
source is it anyway???

-- 
It feels good to be home on my 486.
http://users.rcn.com/alangrimes/

Follow-Ups: References: