qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PULL 13/76] pvh: Add x86/HVM direct boot ABI header fi


From: Stefano Garzarella
Subject: Re: [Qemu-devel] [PULL 13/76] pvh: Add x86/HVM direct boot ABI header file
Date: Sat, 2 Mar 2019 11:17:58 +0100
User-agent: NeoMutt/20180716

On Fri, Mar 01, 2019 at 05:56:36PM +0000, Alex Bennée wrote:
> 
> Stefano Garzarella <address@hidden> writes:
> 
> > On Fri, Mar 01, 2019 at 04:53:57PM +0000, Alex Bennée wrote:
> >>
> >> Paolo Bonzini <address@hidden> writes:
> >>
> >> > From: Liam Merwick <address@hidden>
> >> >
> >> > The x86/HVM direct boot ABI permits Qemu to be able to boot directly
> >> > into the uncompressed Linux kernel binary with minimal firmware 
> >> > involvement.
> >> >
> >> >  https://xenbits.xen.org/docs/unstable/misc/pvh.html
> >> >
> >> > This commit adds the header file that defines the start_info struct
> >> > that needs to be populated in order to use this ABI.
> >> >
> >> > The canonical version of start_info.h is in the Xen codebase.
> >> > (like QEMU, the Linux kernel uses a copy as well).
> >> >
> >> > Signed-off-by: Liam Merwick <address@hidden>
> >> > Reviewed-by: Konrad Rzeszutek Wilk <address@hidden>
> >> > Signed-off-by: Paolo Bonzini <address@hidden>
> >>
> >> This has changed behaviour of a boot. Previously:
> >>
> >>   qemu-system-i386 -serial mon:stdio -nographic -device \
> >>      isa-debugcon,chardev=serial0 -kernel ./tests/hello
> >>
> >
> > Hi Alex,
> > is your image in multiboot format?
> 
> AFAICT yes, I'm not super familiar with x86 so I'm mostly cribbing from:
> 
>   https://github.com/doug65536/qemu-bmibug
> 
> > I sent a patch few weeks ago that fix the loading of multiboot images:
> > https://www.mail-archive.com/address@hidden/msg596424.html
> 
> That certainly fixes things. Although I'm wondering if it's worth making
> my test image PVH compatible anyway (if it's easy to do) as all I really
> want to do is exercise the softmmu code. It might be simpler to use
> paravirtualised serial ports rather than banging an IO port, IDK?

I don't have a lot of experience too, but I don't think there are a lot
of differences in terms of how to use ports.

Multiboot and PVH change the way how to jump to your image.
Both provide a structure where your image can found the e820 memory map and
PVH provides also the RSDP (ACPI) pointer.

Maybe create a PVH image should be simpler because you only need to put in the
ELF note the entry point of your ELF image. Then, EBX will contain the address
of start_info structure (where you can find the e820 mmap).

You can take a look of this file in Linux: arch/x86/platform/pvh/head.S

I hope this can help :)

Cheers,
Stefano



reply via email to

[Prev in Thread] Current Thread [Next in Thread]