Hi.
I am writing a simple 32-bit protected mode kernel and now I plan to start implementing memory management tools, for this I should refer to the information that GRUB gives me. I am currently using the multiboot specification of the first version and I am thinking whether it is worth implementing multiboot2 first. Should I use multiboot2 in my core? What will it give me?
Please advise how to solve this issue.
Do I need multiboot2?
-
- Member
- Posts: 5560
- Joined: Mon Mar 25, 2013 7:01 pm
Re: Do I need multiboot2?
For memory management, the only thing Multiboot2 gives you that Multiboot doesn't is the relocatable header tag, which you can use to tell the bootloader it can load your kernel at a different address if the one you specified in your linker script isn't available. If you're not planning on using that tag, then Multiboot2 makes no real difference to your memory management. (UEFI doesn't guarantee memory will be available at 1MiB the way legacy BIOS does, so the relocatable header tag gives you a way to make your OS run on more PCs. However, you have to write the code to handle being loaded at a different address.)
In general, Multiboot2 gives you better UEFI support. Even if you don't use the relocatable header tag, it still gives you access to the EFI system table and the ACPI RSDP on UEFI PCs.
In general, Multiboot2 gives you better UEFI support. Even if you don't use the relocatable header tag, it still gives you access to the EFI system table and the ACPI RSDP on UEFI PCs.
Re: Do I need multiboot2?
Does GRUB boot the kernel using UEFI or BIOS? I would like to be sure that the BIOS will boot me, how can I ask GRUB for this?Octocontrabass wrote:UEFI doesn't guarantee memory will be available at 1MiB the way legacy BIOS does
-
- Member
- Posts: 5560
- Joined: Mon Mar 25, 2013 7:01 pm
Re: Do I need multiboot2?
GRUB uses whatever is available.mrjbom wrote:Does GRUB boot the kernel using UEFI or BIOS?
GRUB doesn't control that. If you want to choose BIOS or UEFI, you have to use the firmware's boot menu. Some new PCs don't support BIOS.mrjbom wrote:I would like to be sure that the BIOS will boot me, how can I ask GRUB for this?