diff --git a/arch/x86_64/boot.s b/arch/x86_64/boot.s index 8d77171..c3f3cb6 100644 --- a/arch/x86_64/boot.s +++ b/arch/x86_64/boot.s @@ -37,10 +37,10 @@ multiboot2_header: /* Framebuffer Request Tag (Type 5) - Requests UEFI GOP / VBE native @ 32bpp */ .align 8 .short 5 /* type = 5 (Framebuffer) */ - .short 0 /* flags = 0 (Required graphics mode) */ + .short 0 /* flags = 0 */ .long 20 /* size = 20 bytes */ - .long 0 /* width = 0 (no preference / native panel) */ - .long 0 /* height = 0 (no preference / native panel) */ + .long 1920 /* width = 1920 (FHD Native for Acer Nitro V 15) */ + .long 1080 /* height = 1080 (FHD Native for Acer Nitro V 15) */ .long 32 /* depth = 32bpp */ /* End tag */ diff --git a/kernel/kmain.c b/kernel/kmain.c index 87c123c..a0a3326 100644 --- a/kernel/kmain.c +++ b/kernel/kmain.c @@ -60,7 +60,7 @@ void kernel_main(uint64_t magic, uint64_t addr) { if (tag_type == 0 || tag_size == 0) break; - if (tag_type == 16) { /* Tag 16: Framebuffer tag */ + if (tag_type == 8 || tag_type == 16) { /* Tag 8: Multiboot2 Framebuffer Info Tag */ uint64_t fb_phys = *(volatile uint64_t*)(tag_ptr + 8); uint32_t pitch = *(volatile uint32_t*)(tag_ptr + 16); uint32_t w = *(volatile uint32_t*)(tag_ptr + 20); @@ -70,6 +70,7 @@ void kernel_main(uint64_t magic, uint64_t addr) { if (fb_phys != 0 && fb_phys < (128ULL * 1024 * 1024 * 1024) && w >= 320 && h >= 200) { vbe_set_physical_framebuffer(fb_phys, w, h, pitch, (uint32_t)bpp); vbe_early_boot_splash(); + serial_puts("[AIRLYS] UEFI GOP Framebuffer bound to physical display!\n"); break; } }