From 1f22d0c90050b77da9e5a22cdf05828b9bf188b2 Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Tue, 20 Oct 2020 17:34:08 -0400 Subject: [PATCH] add a few multiboot2 info structures --- src/multiboot2.h | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/src/multiboot2.h b/src/multiboot2.h index 797deca..f5603a5 100644 --- a/src/multiboot2.h +++ b/src/multiboot2.h @@ -68,6 +68,39 @@ typedef struct { #define multiboot2_info_next_tag(current_tag) \ (multiboot2_info_tag_t *)(((uintptr_t)current_tag + current_tag->size + MULTIBOOT2_INFO_TAG_ALIGNMENT - 1u) & ~(MULTIBOOT2_INFO_TAG_ALIGNMENT - 1u)) +typedef struct { + multiboot2_info_tag_t header; + uint8_t string[]; +} multiboot2_info_boot_loader_name_t; + +typedef struct { + multiboot2_info_tag_t header; + uint32_t mem_lower; + uint32_t mem_upper; +} multiboot2_info_basic_memory_info_t; + +typedef struct { + multiboot2_info_tag_t header; + uint32_t entry_size; + uint32_t entry_version; + struct { + uint64_t base_addr; + uint64_t length; + uint32_t type; + uint32_t _reserved; + } entries[]; +} multiboot2_info_memory_map_t; + +typedef struct { + multiboot2_info_tag_t header; + uint16_t vbe_mode; + uint16_t vbe_interface_set; + uint16_t vbe_interface_off; + uint16_t vbe_interface_len; + uint8_t vbe_control_info[512]; + uint8_t vbe_mode_info[256]; +} multiboot2_info_vbe_info_t; + typedef struct { multiboot2_info_tag_t header; uint64_t framebuffer_addr;