next up previous
Next: Second Stage - Up: Boot-strap Loader Previous: Boot-strap Loader

First Stage - Loading the Kernel

The first stage is loaded from the first sector on the floppy disk. The BIOS checks the first sector to see if it has a boot signature (the value 0x55aa in the last two bytes of the sector). If the sector does have that signature, the BIOS loads that sector into memory at segment 0x07c0:0. At this point the processor is in 16-bit ``real'' mode, which still uses the Intel segmented architecture. This entire stage is hand-written assembly code, loosely based on code from the Mach operating system boot-strap. It is cross-assembled using gcc to produce a 512 byte 16-bit mode boot sector. It sole purpose is to load the second stage boot strap at an fixed and arbitrary address, 0x1000:0, and jump to the second stage entry point, kick_start.

Paco Hope
Wed Jun 21 23:54:28 EDT 1995