#include <oskit/x86/pc/base_multiboot.h>
The first thing that multiboot_main does on entry from the minimal startup code in multiboot.o is copy the MultiBoot information structure passed by the boot loader into a global variable in the kernel's bss segment. Copying the information structure this way allows it to be accessed more conveniently by the kernel, and makes it unnecessary for the memory initialization code (base_multiboot_init_mem; see Section 10.14.9) to carefully ``step over'' the information structure when determining what physical memory is available for general use.After the OS has received control in its main routine, it is free to examine the boot_info structure and use it to locate other data passed by the boot loader, such as the boot modules. The client OS must not attempt to access the original copy of the information structure passed by the boot loader, since that copy of the structure may be overwritten as memory is dynamically allocated and used. However, this should not be a problem, since a pointer to the original copy of the multiboot_info structure is never even passed to the OS by the MultiBoot startup code; it is only accessible to the OS if it overrides the multiboot_main function.