14 #ifndef L4UTIL_MB_INFO_H
15 #define L4UTIL_MB_INFO_H
23 #include <l4/sys/l4int.h>
49 typedef struct __attribute__((packed))
59 #define MB_ARD_MEMORY 1
65 #define MB_ART_MEMORY 1
66 #define MB_ART_RESERVED 2
70 #define MB_ART_UNUSABLE 5
86 #define MB_DI_CHS_MODE 0
87 #define MB_DI_LBA_MODE 1
286 #define l4util_mb_for_each_mmap_entry(i, mbi) \
287 for (i = l4util_mb_first_mmap_entry(mbi); \
288 (unsigned long)i < (unsigned long)mbi->mmap_addr + mbi->mmap_length; \
289 i = l4util_mb_next_mmap_entry(i))
298 #define L4UTIL_MB_MEMORY 0x00000001
301 #define L4UTIL_MB_BOOTDEV 0x00000002
304 #define L4UTIL_MB_CMDLINE 0x00000004
307 #define L4UTIL_MB_MODS 0x00000008
311 #define L4UTIL_MB_AOUT_SYMS 0x00000010
314 #define L4UTIL_MB_ELF_SHDR 0x00000020
317 #define L4UTIL_MB_MEM_MAP 0x00000040
320 #define L4UTIL_MB_DRIVE_INFO 0x00000080
323 #define L4UTIL_MB_CONFIG_TABLE 0x00000100
326 #define L4UTIL_MB_BOOT_LOADER_NAME 0x00000200
329 #define L4UTIL_MB_APM_TABLE 0x00000400
332 #define L4UTIL_MB_VIDEO_INFO 0x00000800
336 #define L4UTIL_MB_VALID 0x2BADB002UL
337 #define L4UTIL_MB_VALID_ASM 0x2BADB002
350 } __attribute__((packed)) l4util_mb2_info_t;
355 } __attribute__((packed)) l4util_mb2_cmdline_tag_t;
362 } __attribute__((packed)) l4util_mb2_module_tag_t;
370 } __attribute__((packed)) l4util_mb2_memmap_entry_t;
376 l4util_mb2_memmap_entry_t entries[];
377 } __attribute__((packed)) l4util_mb2_memmap_tag_t;
382 } __attribute__((packed)) l4util_mb2_rsdp_tag_t;
391 l4util_mb2_cmdline_tag_t cmdline;
392 l4util_mb2_module_tag_t module;
393 l4util_mb2_memmap_tag_t memmap;
394 l4util_mb2_rsdp_tag_t rsdp;
396 } __attribute__((packed)) l4util_mb2_tag_t;
401 #define L4UTIL_MB2_MAGIC 0xE85250D6
402 #define L4UTIL_MB2_ARCH_I386 0x0
404 #define L4UTIL_MB2_TERMINATOR_HEADER_TAG 0
405 #define L4UTIL_MB2_INFO_REQUEST_HEADER_TAG 1
406 #define L4UTIL_MB2_ENTRY_ADDRESS_HEADER_TAG 3
407 #define L4UTIL_MB2_RELOCATABLE_HEADER_TAG 10
409 #define L4UTIL_MB2_TAG_FLAG_REQUIRED 0
411 #define L4UTIL_MB2_TAG_ALIGN_SHIFT 3
412 #define L4UTIL_MB2_TAG_ALIGN 8
414 #define L4UTIL_MB2_TERMINATOR_INFO_TAG 0
415 #define L4UTIL_MB2_BOOT_CMDLINE_INFO_TAG 1
416 #define L4UTIL_MB2_MODULE_INFO_TAG 3
417 #define L4UTIL_MB2_MEMORY_MAP_INFO_TAG 6
418 #define L4UTIL_MB2_RSDP_OLD_INFO_TAG 14
419 #define L4UTIL_MB2_RSDP_NEW_INFO_TAG 15
420 #define L4UTIL_MB2_IMAGE_LOAD_BASE_PHYS_INFO_TAG 21
422 #define L4UTIL_MB2_RELO_PREFERED_NONE 0
423 #define L4UTIL_MB2_RELO_PREFERED_MIN 1
424 #define L4UTIL_MB2_RELO_PREFERED_MAX 2
unsigned long l4_addr_t
Address type.
unsigned char l4_uint8_t
Unsigned 8bit value.
unsigned int l4_uint32_t
Unsigned 32bit value.
unsigned short int l4_uint16_t
Unsigned 16bit value.
unsigned long long l4_uint64_t
Unsigned 64bit value.
INT-15, AX=E820 style "AddressRangeDescriptor" ...with a "size" parameter on the front which is the s...
l4_uint32_t type
type of memory range
l4_uint64_t size
Size of memory range.
l4_uint64_t addr
Start address.
l4_uint32_t struct_size
Size of structure.
l4_uint8_t drive_number
<The size of this structure.
l4_uint8_t drive_mode
<The BIOS drive number.
l4_uint16_t drive_cylinders
<The access mode (see below).
l4_uint8_t drive_sectors
<number of heads
l4_uint8_t drive_heads
<number of cylinders
MultiBoot Info description.
l4_uint32_t drives_length
size of drive info buffer
l4_uint32_t num
(ELF) Kernel section header table
l4_uint16_t vbe_mode
VESA video mode number.
l4_uint32_t mmap_length
size of memory mapping buffer
l4_uint16_t vbe_interface_len
VESA lenght of prot BIOS interface.
l4_uint32_t drives_addr
address of driver info buffer
l4_uint32_t mem_upper
available memory starting from 1MB [kB]
l4_uint32_t tabsize
(a.out) Kernel symbol table info
l4_uint32_t boot_device
"root" partition
l4_uint32_t apm_table
APM table.
l4_uint32_t cmdline
Kernel command line.
l4_uint32_t config_table
ROM configuration table.
l4_uint16_t vbe_interface_off
VESA offset of prot BIOS interface.
l4_uint32_t mem_lower
available memory below 1MB
l4_uint32_t mmap_addr
address of memory mapping buffer
l4_uint32_t vbe_mode_info
VESA video mode info.
l4_uint32_t vbe_ctrl_info
VESA video contoller info.
l4_uint32_t mods_addr
module list
l4_uint32_t mods_count
number of modules
l4_uint32_t boot_loader_name
Boot Loader Name.
l4_uint32_t flags
MultiBoot info version number.
l4_uint16_t vbe_interface_seg
VESA segment of prot BIOS interface.
The structure type "mod_list" is used by the multiboot_info structure.
l4_uint32_t mod_start
Starting address of module in memory.
l4_uint32_t pad
padding to take it to 16 bytes
l4_uint32_t cmdline
Module command line.
l4_uint32_t mod_end
End address of module in memory.
VBE controller information.