Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Zygoma::ia32::MultibootInfo Struct Reference
[Bootstrapping]

#include <multiboot.h>

List of all members.


Detailed Description

Structure passed to the OS by the multiboot loader on startup.

When the bootloader invokes the OS entry point, the address of this structure is passed in register EBX, and register EAX must contain the hexidecimal magic '0x2BADBOO2'.


Memory Fields

u32 mem_lower () const
 Gets the amount of 'lower' memory in the system, in kilobytes.
u32 mem_upper () const
 Gets the amount of 'upper' memory available in the system, in kilobytes.

The Boot Device

The 'boot device' value is a bitmap of BIOS disk devices and partitions from which the kernel was invoked. Not sure how this is mapped since the spec is vague about what a 'BIOS' is and how bytes are layed out in 32-bit words.

u32 boot_device () const
 Gets a bitmap describing whence the kernel was invoked.

The Command Line

const char * cmdline () const
 Gets the command line used to invoke the load module.

The System Memory Map

Valid only if m_flags has the kFLAG_MMAP_FIELDS_VALID bit set.

MemoryMapDescriptormemoryMapBase ()
 Gets the address of the first memory map descriptor supplied by the multiboot loader.
u32 memoryMapLength ()
 Gets the number of entries in the memory map supplied by the multiboot loader.

The Boot Loader Name

const char * boot_loader_name () const
 Gets the name of the program used to invoke the load module.

Public Attributes

u32 m_flags
Additional Load Modules
Valid only if m_flags has the kFLAG_MODULES_FIELDS_VALID bit set.

u32 m_mods_count
 The number of additional modules loaded with the kernel image.
u32 m_mods_addr
 The physical address of the first module desriptor.
The Symbol Table
u32 m_syms [4]
The Disk Drives Map
Valid only if m_flags has the kFLAG_DRIVES_FIELDS_VALID bit set.

u32 m_drives_length
u32 m_drives_addr
The System Configuration
Valid only if m_flags has the kFLAG_CONFIG_FIELDS_VALID bit set.

u32 m_config_table
Advanced Power Management
Valid only if m_flags has the kFLAG_APM_FIELDS_VALID bit set.

u32 m_apm_table
Video Display Information
Valid only if m_flags has the kFLAG_GRAPHICS_FIELDS_VALID bit set.

u32 m_vbe_control_info
u32 m_vbe_mode_info
u32 m_vbe_mode
u16 m_vbe_interface_seg
u16 m_vbe_interface_of
u16 m_vbe_interface_len

Static Public Attributes

static const u32 kMAGIC = 0x2BADB002
static const u32 kFLAG_MEM_FIELDS_VALID = (1 << 0)
static const u32 kFLAG_BOOT_DEVICE_FIELDS_VALID = (1 << 1)
static const u32 kFLAG_CMDLINE_FIELDS_VALID = (1 << 2)
static const u32 kFLAG_MODULES_FIELDS_VALID = (1 << 3)
static const u32 kFLAG_AOUT_FIELDS_VALID = (1 << 4)
static const u32 kFLAG_ELF_FIELDS_VALID = (1 << 5)
static const u32 kFLAG_MMAP_FIELDS_VALID = (1 << 6)
static const u32 kFLAG_DRIVES_FIELDS_VALID = (1 << 7)
static const u32 kFLAG_CONFIG_FIELDS_VALID = (1 << 8)
static const u32 kFLAG_LOADER_NAME_FIELDS_VALID = (1 << 9)
static const u32 kFLAG_APM_FIELDS_VALID = (1 << 10)
static const u32 kFLAG_GRAPHICS_FIELDS_VALID = (1 << 11)


Member Function Documentation

u32 Zygoma::ia32::MultibootInfo::boot_device  )  const [inline]
 

Gets a bitmap describing whence the kernel was invoked.

Returns:
A value of unknown description.

const char* Zygoma::ia32::MultibootInfo::boot_loader_name  )  const [inline]
 

Gets the name of the program used to invoke the load module.

Returns:
a pointer to a C-style null-terminated multibyte string containing the command line used to invoke the load mode, or a null string if there is no command line available.

const char* Zygoma::ia32::MultibootInfo::cmdline  )  const [inline]
 

Gets the command line used to invoke the load module.

Returns:
A pointer to a C-style null-terminated multibyte string containing the command line used to invoke the load module, or an empty string if there is no command line available.

u32 Zygoma::ia32::MultibootInfo::mem_lower  )  const [inline]
 

Gets the amount of 'lower' memory in the system, in kilobytes.

Lower memory is memory with an address between 0x00000000 and 0x000a0000 (640 kB).

Returns:
The amount of lower memory available in kilobytes.

u32 Zygoma::ia32::MultibootInfo::mem_upper  )  const [inline]
 

Gets the amount of 'upper' memory available in the system, in kilobytes.

Upper memory is memory with an address greater than 0x00100000 (1 MB).

Returns:
The amount of upper memory available in kilobytes.

MemoryMapDescriptor* Zygoma::ia32::MultibootInfo::memoryMapBase  )  [inline]
 

Gets the address of the first memory map descriptor supplied by the multiboot loader.

Returns:
A pointer to a vector of MemoryMapDescriptor structures, each describing a valid region of system RAM memory.

u32 Zygoma::ia32::MultibootInfo::memoryMapLength  )  [inline]
 

Gets the number of entries in the memory map supplied by the multiboot loader.

Calculating the size of this table is a little wacky because of some fancy dancing the class designers did for backwards compatibility.

Returns:
The number of entries in the memory map vector.


Member Data Documentation

const u32 Zygoma::ia32::MultibootInfo::kFLAG_AOUT_FIELDS_VALID = (1 << 4) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_APM_FIELDS_VALID = (1 << 10) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_BOOT_DEVICE_FIELDS_VALID = (1 << 1) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_CMDLINE_FIELDS_VALID = (1 << 2) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_CONFIG_FIELDS_VALID = (1 << 8) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_DRIVES_FIELDS_VALID = (1 << 7) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_ELF_FIELDS_VALID = (1 << 5) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_GRAPHICS_FIELDS_VALID = (1 << 11) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_LOADER_NAME_FIELDS_VALID = (1 << 9) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_MEM_FIELDS_VALID = (1 << 0) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_MMAP_FIELDS_VALID = (1 << 6) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kFLAG_MODULES_FIELDS_VALID = (1 << 3) [static]
 

const u32 Zygoma::ia32::MultibootInfo::kMAGIC = 0x2BADB002 [static]
 

u32 Zygoma::ia32::MultibootInfo::m_apm_table
 

u32 Zygoma::ia32::MultibootInfo::m_config_table
 

u32 Zygoma::ia32::MultibootInfo::m_drives_addr
 

u32 Zygoma::ia32::MultibootInfo::m_drives_length
 

u32 Zygoma::ia32::MultibootInfo::m_flags
 

u32 Zygoma::ia32::MultibootInfo::m_mods_addr
 

The physical address of the first module desriptor.

u32 Zygoma::ia32::MultibootInfo::m_mods_count
 

The number of additional modules loaded with the kernel image.

u32 Zygoma::ia32::MultibootInfo::m_syms[4]
 

u32 Zygoma::ia32::MultibootInfo::m_vbe_control_info
 

u16 Zygoma::ia32::MultibootInfo::m_vbe_interface_len
 

u16 Zygoma::ia32::MultibootInfo::m_vbe_interface_of
 

u16 Zygoma::ia32::MultibootInfo::m_vbe_interface_seg
 

u32 Zygoma::ia32::MultibootInfo::m_vbe_mode
 

u32 Zygoma::ia32::MultibootInfo::m_vbe_mode_info
 


The documentation for this struct was generated from the following file:
Generated on Fri Sep 2 10:45:13 2005 for zygoma by doxygen 1.4.2