From 958e2dae042ca9e28f23e509d541730f30fa8502 Mon Sep 17 00:00:00 2001 From: Loic Guegan Date: Thu, 8 Apr 2021 13:07:17 +0200 Subject: Switch to multiboot2 and improve interrupt management --- src/utils/multiboot.h | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 src/utils/multiboot.h (limited to 'src/utils/multiboot.h') diff --git a/src/utils/multiboot.h b/src/utils/multiboot.h new file mode 100644 index 0000000..4194d00 --- /dev/null +++ b/src/utils/multiboot.h @@ -0,0 +1,32 @@ +#ifndef MULTIBOOT_H +#define MULTIBOOT_H + +#include "types.h" + +typedef struct MBI_TAG_HEADER { + u32 type; + u32 size; +} __attribute__((packed)) MBI_TAG_HEADER; + +typedef struct MBI_TAG_BL_NAME { + MBI_TAG_HEADER header; + u8 *name; +} __attribute__((packed)) MBI_TAG_BL_NAME; + + +typedef struct MBI_TAG_FB { + MBI_TAG_HEADER header; + u64 framebuffer_addr; + u32 framebuffer_pitch; + u32 framebuffer_width; + u32 framebuffer_height; + u8 framebuffer_bpp; + u8 framebuffer_type; + u8 reserved; + u8 *color_infos; +}__attribute__((packed)) MBI_TAG_FB; + + +char mb_load_tag(char **data, char type); +char mb_load_bl_name(MBI_TAG_BL_NAME *data); +#endif \ No newline at end of file -- cgit v1.2.3