BOOT SEQUENCE

This is how the boot goes:

  1. BIOS reads the boot block of a disk into memory
  2. That block reads the rest of the boot file (oz_loader_486.bb) which contains the 'preloader', 'epander' and the 'loader' (ozone_boot_486.s)
  3. The preloader switches from 16-bit to 32-bit mode. It also sets up a grody routine that the alternate cpu's use to switch from 16-bit to 32-bit mode. (oz_preloader_486.s)
  4. The expander gunzips the loader and stores it starting at address 0x00400000 (oz_ldr_expand_486.s). I used to have the loader start at 0x0000A000 up to the memory hole, but it got to be too big. So now it loads there originally in gzip format, but the expander expands it and puts the expansion at the 4M boundary. I used 4M because that should leave plenty of room for the kernel which loads just above the memory hole, and leaves the PD entry for the first 4M alone.
  5. The loader initializes its data structures, initializes device drivers then processes any commands given from the keyboard and from any loader script, then it reads in the kernel from a load device such as a disk or network (oz_loader_486.s and oz_ldr_loader.c)
  6. The kernel does the following:
    1. sets up internal data structures (oz_kernel_486.s and oz_knl_boot.c)
    2. defines some system logical names (like where the boot device and directory are) (oz_knl_boot.c)
    3. starts the alternate cpus (oz_knl_boot.c)
    4. initializes device drivers (oz_knl_boot.c)
    5. mounts the system disk (oz_knl_startup.c)
    6. starts the cli (shell) to process the startup script (oz_knl_startup.c)


Once the system is booted, it runs the image specified by loader parameter 'startup_image', usually set to oz_cli.oz. The image is given what is in loader parameters 'startup_input', 'startup_output', 'startup_error' for its I/O files, and 'startup_params' for its command line. So usually this does things like create logical names needed by stuff and starts daemons, etc. I have it run '../startup/hardiskstartup.cli'.

Then, when it finishes that stuff, you can log on by pressing control-shift-L. It should prompt for an username and password. I am sending a ../startup/password.dat file out that has 'root' for the username and 'tree' for the password. Type HELP and oz_cli will list out commands.