#include <multiboot.h>
The OS image must supply this header to the loader.
Graphics Fields | |
These fields specify the recommended graphics mode of the OS image.
These fields are enabled if the | |
enum | GraphicsMode { kGRAPHMODE_GRAPHICS = 0, kGRAPHMODE_TEXT = 1 } |
*u32 | m_mode_type |
Indicates the preferred video display mode. | |
u32 | m_width |
The number of columns in the text display. | |
u32 | m_height |
The number of rows in the text display. | |
u32 | m_depth |
The number of bits per pixel in mode 0. | |
Base (required) fields | |
These fields are required and must appear in the multiboot header. All other fields are optional. | |
*u32 | m_magic |
The magic number identifying the header. | |
u32 | m_flags |
Specifies the features that the OS image requests or requires of the boot loader. | |
u32 | m_checksum |
Value that, when added to the sum of the m_magic and m_flags fields, yields an unsigned 32-bit sum of zero. | |
static const u32 | kMAGIC = 0x1BADB002 |
The MultibootHeader m_magic must contain this value. | |
static const u32 | kFLAGS_ALIGN_ON_4K = (1 << 0) |
static const u32 | kFLAGS_INCLUDE_MEM_FIELDS = (1 << 1) |
static const u32 | kFLAGS_VIDEO_FIELDS_INCLUDED = (1 << 2) |
static const u32 | kFLAGS_ADDRESS_FIELDS_INCLUDED = (1 << 16) |
Public Attributes | |
Address Fields | |
These fields describe the load region of the image to the multiboot loader. | |
*u32 | m_header_addr |
The physical memory location at which the MultibootHeader starts. | |
u32 | m_load_addr |
The physical address of the beginning of the beginning of the 'text' segment. | |
u32 | m_load_end_addr |
The physical address of the end of the data segment. | |
u32 | m_bss_end_addr |
The physical address of the end of the 'bss' segment. | |
u32 | m_entry_addr |
The physical address of the OS entry point. |
|
|
|
|
|
|
|
|
|
|
|
The MultibootHeader m_magic must contain this value.
|
|
The physical address of the end of the 'bss' segment.
|
|
Value that, when added to the sum of the
|
|
The number of bits per pixel in mode 0. A value of zero indicates no preference. |
|
The physical address of the OS entry point.
|
|
Specifies the features that the OS image requests or requires of the boot loader.
|
|
The physical memory location at which the MultibootHeader starts.
|
|
The number of rows in the text display. The unit is pixels in mode 0, characters in mode 1. A value of zero indicates no preference. |
|
The physical address of the beginning of the beginning of the 'text' segment.
|
|
The physical address of the end of the data segment. The multiboot loader assumes that the 'text' segment and 'data' segment are contuguous and the 'text' segment preceeds te 'data' segment. |
|
The magic number identifying the header. Must be the hexadecimal value kMAGIC. |
|
Indicates the preferred video display mode.
|
|
The number of columns in the text display. The unit is pixels in mode 0, characters in mode 1. A value of zero indicates no preference. |