On 18/01/19 13:01, Stefano Garzarella wrote: > The new pvh.bin option rom can be used with SeaBIOS to boot > uncompressed kernel using the x86/HVM direct boot ABI. > > pvh.S contains the entry point of the option rom. It runs > in real mode, loads the e820 table querying the BIOS, and > then it switches to 32bit protected mode and jumps to the > pvh_load_kernel() written in pvh_main.c. > pvh_load_kernel() loads the cmdline and kernel entry_point > using fw_cfg, then it looks for RSDP, fills the > hvm_start_info required by x86/HVM ABI, and finally jumps > to the kernel entry_point. > > Signed-off-by: Stefano Garzarella <sgarz...@redhat.com> > Reviewed-by: Stefan Hajnoczi <stefa...@redhat.com> > Reviewed-by: Liam Merwick <liam.merw...@oracle.com>
... and, for mingw: diff --git a/pc-bios/optionrom/pvh_main.c b/pc-bios/optionrom/pvh_main.c index d1b8b4b..a015e1b 100644 --- a/pc-bios/optionrom/pvh_main.c +++ b/pc-bios/optionrom/pvh_main.c @@ -43,7 +43,7 @@ struct pvh_e820_table { struct hvm_memmap_table_entry table[E820_MAXENTRIES]; }; -struct pvh_e820_table pvh_e820 __attribute__ ((aligned)); +struct pvh_e820_table pvh_e820 asm("pvh_e820") __attribute__ ((aligned)); static struct hvm_start_info start_info; static struct hvm_modlist_entry ramdisk_mod; Paolo