Jump to content

Booting Clover from GRUB2


Melab
 Share

4 posts in this topic

Recommended Posts

I've searched for this and I've found nothing that addresses this.

 

Is there a way to boot Clover's EfiLdr file (named "boot"), and possibly load the EfiVar.bin file alongside it, directly from GRUB2? That means without loading any of the intermediate boot sector files. If possible, can this be done loading it as a multiboot image (there are two specifications: multiboot and multiboot2).

Link to comment
Share on other sites

6 hours ago, Melab said:

I've searched for this and I've found nothing that addresses this.

 

Is there a way to boot Clover's EfiLdr file (named "boot"), and possibly load the EfiVar.bin file alongside it, directly from GRUB2? That means without loading any of the intermediate boot sector files. If possible, can this be done loading it as a multiboot image (there are two specifications: multiboot and multiboot2).

I can't say this is impossible but this is the question rather to grub2 developers if they can reproduce bootsectors behaviors and start some file in real mode with set of predefined cpu registers.

Clover itself resolved similar task and the procedure exists in the file LegacyBoot.cpp.

Link to comment
Share on other sites

  • 3 weeks later...
On 7/23/2020 at 12:44 AM, Slice said:

I can't say this is impossible but this is the question rather to grub2 developers if they can reproduce bootsectors behaviors and start some file in real mode with set of predefined cpu registers.

Clover itself resolved similar task and the procedure exists in the file LegacyBoot.cpp.

Does Clover's EfiLdr have to start in real mode? Am I correct in believing that it's produced by concatenating several files? And that one of those files contains the code that runs in protected mode?

 

Assuming that I choose to chainload the boot sector files from GRUB2 in order to load Clover, do I have to chainload boot0ss or can GRUB2 jump to boot1f32 instead? Can I load boot1f32 from a file or does it have to be installed to the ESP's PBR?

Link to comment
Share on other sites

Yes, first code switches execution into protected mode. In theory you can start execution here preparing all memory and registers to work.

If you want a chainload then look into LegacyBoot.cpp which did this. But the problem is PCI devices which were not properly initialised this way. For example SATA controller remains in undefined state.

Link to comment
Share on other sites

 Share

×
×
  • Create New...